大网数据广告活动
服务器运维问答

PATH issues with gitlab-runner on centos 8

· 52CE 我爱测

I'm having an issue when trying to use the gitlab runner I installed in my centos 8 server. So here are the details: I followed the instructions here to install: https://docs.gitlab.com/runner/install/linux-manually.html I downlo…

问题原文

原帖链接 · RyanH · CC BY-SA 4.0

I'm having an issue when trying to use the gitlab runner I installed in my centos 8 server.

So here are the details:

I followed the instructions here to install: https://docs.gitlab.com/runner/install/linux-manually.html

I downloaded and installed their rpm package then ran it and registered it, using the shell executor

So far so good.

The issue is that when the runner tries to run a pipeline, I get this error:

ERROR: Job failed (system failure): Failed to start process: exec: "su": executable file not found in $PATH

There is a similar issue with the runner on nixOS, apparently, but I'm unsure how I would apply the workaround.

https://github.com/NixOS/nixpkgs/issues/53985

So I'm unsure whether I messed something up during install at some point or not; and whether I can fix it or apply a workaround, but any help would be appreciated.

Thanks.

已采纳解答

原帖链接 · Stefan · CC BY-SA 4.0

Maybe SELinux is enabled by default.
Test with getenforce or sealert -a /var/log/audit/audit.log on gitlab-runner

That was my Problem with RHEL8 and gitlab-runner.

You can temporary disable SELinux with setenforce 0 and try to run CI/CD job again.

After disabling SELinux or adding the missing rules it works fine for me.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2019-11-18)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。