Comments (7)
I do know there where some changes with the become rights, if you could verify that would be nice.
from ansible-gitlab-runner.
Yes I can verify this. Here is the output without the become: yes
on those two tasks:
TASK [gitlab-runner : (Unix) List configured runners] *******************************************************************************************************************************************
ok: [runner] => {"changed": false, "cmd": ["gitlab-runner", "list"], "delta": "0:00:00.036978", "end": "2019-12-13 12:46:41.930483", "rc": 0, "start": "2019-12-13 12:46:41.893505", "stderr": "Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=9982 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0\nListing configured runners \u001b[0;m ConfigFile\u001b[0;m=/home/ec2-user/.gitlab-runner/config.toml", "stderr_lines": ["Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=9982 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0", "Listing configured runners \u001b[0;m ConfigFile\u001b[0;m=/home/ec2-user/.gitlab-runner/config.toml"], "stdout": "", "stdout_lines": []}
TASK [gitlab-runner : (Unix) Check runner is registered] ****************************************************************************************************************************************
ok: [runner] => {"changed": false, "cmd": ["gitlab-runner", "verify"], "delta": "0:00:00.060844", "end": "2019-12-13 12:46:42.791398", "rc": 0, "start": "2019-12-13 12:46:42.730554", "stderr": "Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=10060 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0\n\u001b[0;33mWARNING: Running in user-mode. \u001b[0;m \n\u001b[0;33mWARNING: The user-mode requires you to manually start builds processing:\u001b[0;m \n\u001b[0;33mWARNING: $ gitlab-runner run \u001b[0;m \n\u001b[0;33mWARNING: Use sudo for system-mode: \u001b[0;m \n\u001b[0;33mWARNING: $ sudo gitlab-runner... \u001b[0;m \n \u001b[0;m ", "stderr_lines": ["Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=10060 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0", "\u001b[0;33mWARNING: Running in user-mode. \u001b[0;m ", "\u001b[0;33mWARNING: The user-mode requires you to manually start builds processing:\u001b[0;m ", "\u001b[0;33mWARNING: $ gitlab-runner run \u001b[0;m ", "\u001b[0;33mWARNING: Use sudo for system-mode: \u001b[0;m ", "\u001b[0;33mWARNING: $ sudo gitlab-runner... \u001b[0;m ", " \u001b[0;m "], "stdout": "", "stdout_lines": []}
As you can see in the first, there aren't any runners listed and in the second it warns about needing sudo. (In this test case I did already have a runner registered and running) Also you can see the config file is in my home directory.
Running with become: true
set has the following output:
TASK [gitlab-runner : (Unix) List configured runners] *******************************************************************************************************************************************
ok: [runner] => {"changed": false, "cmd": ["gitlab-runner", "list"], "delta": "0:00:00.030840", "end": "2019-12-13 13:02:35.680896", "rc": 0, "start": "2019-12-13 13:02:35.650056", "stderr": "Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=20420 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0\nListing configured runners \u001b[0;m ConfigFile\u001b[0;m=/etc/gitlab-runner/config.toml\nci \u001b[0;m Executor\u001b[0;m=shell Token\u001b[0;m=EagwTpB1wSWi1evgvigG URL\u001b[0;m=https://gitlab.com/ci", "stderr_lines": ["Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=20420 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0", "Listing configured runners \u001b[0;m ConfigFile\u001b[0;m=/etc/gitlab-runner/config.toml", "ci \u001b[0;m Executor\u001b[0;m=shell Token\u001b[0;m=<my-token> URL\u001b[0;m=https://gitlab.com/ci"], "stdout": "", "stdout_lines": []}
TASK [gitlab-runner : (Unix) Check runner is registered] ****************************************************************************************************************************************
ok: [runner] => {"changed": false, "cmd": ["gitlab-runner", "verify"], "delta": "0:00:02.135855", "end": "2019-12-13 13:02:38.768864", "rc": 0, "start": "2019-12-13 13:02:36.633009", "stderr": "Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=20502 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0\nRunning in system-mode. \u001b[0;m \n \u001b[0;m \nVerifying runner... is alive \u001b[0;m runner\u001b[0;m=<my-token>“, "stderr_lines": ["Runtime platform \u001b[0;m arch\u001b[0;m=amd64 os\u001b[0;m=linux pid\u001b[0;m=20502 revision\u001b[0;m=577f813d version\u001b[0;m=12.5.0", "Running in system-mode. \u001b[0;m ", " \u001b[0;m ", "Verifying runner... is alive \u001b[0;m runner\u001b[0;m=<my-token>“], "stdout": "", "stdout_lines": []}
Here it is using the global config and finds my runner.
I know this is a simple change, but please let me know if you want a PR for it. Thanks
from ansible-gitlab-runner.
PR would be good, think we would need more tests on the build to find these types of issues but thats for another rainy day.
from ansible-gitlab-runner.
PR sent
from ansible-gitlab-runner.
I think it was introduced with #71 btw..
from ansible-gitlab-runner.
Yes, looks like these 2 were overlooked.
from ansible-gitlab-runner.
Think this one can be closed ;p
from ansible-gitlab-runner.
Related Issues (20)
- "The conditional check ''Executor' in json_item' failed HOT 4
- Support of gitlab 15.6+ runners registration way. HOT 13
- "No package matching 'gitlab-runner' is available" HOT 14
- Removed from galaxy HOT 7
- Support for AlmaLinux HOT 3
- Support for (pre,post)_*_script in gitlab-runner config HOT 2
- Set additional services is failing due to missing variable HOT 8
- Invalid config.toml for azure and gcp cache HOT 3
- How to set custom_build_dir_enabled as variable HOT 1
- Error when upgrading from gitlab-runner version 15.0.0 to 16.6.0 HOT 2
- Default branch name HOT 5
- Debian Unhold: Failed to find package from ansible-core >=2.16 HOT 1
- Support for docker tmpfs options HOT 2
- Galaxy role renamed back from ansible-gitlab-runner to gitlab-runner HOT 10
- Reactivating Tests: Topic "systemd and docker" HOT 2
- Causes failures when included by ansible-lint HOT 1
- Can't find package `gitlab-runner` HOT 5
- tls_ca_file not included in container registration HOT 1
- Runtime owner and group for container setup HOT 1
- Deploy multiple executors to single VM
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ansible-gitlab-runner.