diff options
author | lassulus <lassulus@lassul.us> | 2017-09-06 11:07:59 +0200 |
---|---|---|
committer | lassulus <lassulus@lassul.us> | 2017-09-06 11:07:59 +0200 |
commit | 428a5f037ef8a5d6b0ef5bc0ea74dcd458fd5b16 (patch) | |
tree | 0bcc67e7d0f4ff22ca7e4840608f72015a49fbdd /krebs/2configs | |
parent | 6218a259a9880368c71ecacddcf1e7c641bd5278 (diff) | |
parent | a46564bf986829cd7372020ed4962af15a5c5983 (diff) |
Merge remote-tracking branch 'gum/master'
Diffstat (limited to 'krebs/2configs')
-rw-r--r-- | krebs/2configs/gitlab-runner-shackspace.nix | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/krebs/2configs/gitlab-runner-shackspace.nix b/krebs/2configs/gitlab-runner-shackspace.nix new file mode 100644 index 000000000..d9b4cd589 --- /dev/null +++ b/krebs/2configs/gitlab-runner-shackspace.nix @@ -0,0 +1,34 @@ +{ config, ... }: +let + url = "https://git.shackspace.de/"; + # generate token from CI-token via: + ## gitlab-runner register + ## cat /etc/gitlab-runner/config.toml + token = import <secrets/shackspace-gitlab-ci-token.nix> ; +in { + systemd.services.gitlab-runner.path = [ + "/run/wrappers" # /run/wrappers/bin/su + "/" # /bin/sh + ]; + systemd.services.gitlab-runner.serviceConfig.PrivateTmp = true; + virtualisation.docker.enable = true; + services.gitlab-runner = { + enable = true; + # configFile, configOptions and gracefulTimeout not yet in stable + # gracefulTimeout = "120min"; + configText = '' + concurrent = 1 + check_interval = 0 + + [[runners]] + name = "krebs-shell" + url = "${url}" + token = "${token}" + executor = "shell" + shell = "sh" + environment = ["PATH=/bin:/run/wrappers/bin:/etc/per-user/gitlab-runner/bin:/etc/per-user-pkgs/gitlab-runner/bin:/nix/var/nix/profiles/default/bin:/run/current-system/sw/bin"] + [runners.cache] + + ''; + }; +} |