On OSX or Linux just use brew to install:
brew install steffakasid/clinar/clinar
# or
brew tap steffakasid/clinar
#and then
brew install clinar
Checkout brew help
, man brew
clinar [flags]
- GITLAB_HOST
-
set the GitLab host to be able to run against self hosted GitLab instances [Default: https://gitlab.com]
- GITLAB_TOKEN
-
GitLab token to access the GitLab API. To view runners read_api should be sufficient. To cleanup stale runners you must have full API access.
- --approve, -a
-
Boolean flag to toggle approve. If you provide this flag stale runners are deleted.
- --exclude, -e
-
String[] flag (can be provided multiple times). Define projects/ groups based on their names or ids which are excluded. This flag takes precedences before include. If one group/ project is excluded the full runner is excluded from the cleanup list.
- --include, -i
-
String flag to define a regular expressions for projects/ groups which should be included. If one group/ project is included the runner is included into the cleanup list.
You can now provide a sops encrypted config file. To create one you need any supported encryption key e.g. gpg and encrypt your file like the following:
❯ sops --pgp=<GPG Fingerprint> --input-type yaml --output-type yaml $HOME/.clinar
Note
|
You can also add the yaml extension to the filename: $HOME/.clinar.yaml in that case you don’t need to specify --input-type and --output-type
|
- GPG Fingerprint
-
Your gpg fingerprint you can find out with
gpg --list-keys
You can set any flag or env var within the config e.g.: .Content of config file
GITLAB_TOKEN: <gitlab personal token>
GITLAB_HOST: <custom gitlab host>
- gitlab personal token
-
A gitlab personal token can be created in your user profile in GitLab
- custom gitlab host
-
If necessary you can set a custom gitlab host (e.g. a company private one)
The badge is generated using: https://github.com/jpoles1/gopherbadger