Sha256: 067d49c7ec395e511f7a3de6d7ba94ba9d4abe1192ccea181ce81a4eb928cc3d
Contents?: true
Size: 561 Bytes
Versions: 2
Compression:
Stored size: 561 Bytes
Contents
define :register_gitlab_runner, options: [], config: "/etc/gitlab-runner/config.toml" do runner_name = params[:name] config_file = params[:config] raise "name is required. (e.g. register_gitlab_runner 'your_runner_name')" unless runner_name register_args = ["--non-interactive", "--name", runner_name, "--config", config_file] + Array(params[:options]) register_args.compact! execute "gitlab-runner register #{register_args.join(" ")}" do not_if "gitlab-runner list --config #{config_file} 2>&1 1>/dev/null | grep '#{runner_name}'" end end
Version data entries
2 entries across 2 versions & 1 rubygems