Improve registration behavior
What does this MR do?
Adds support for some executor advanced options (like autoscaling settings) while registering. Currently some options that we can use from command line (eg.
gitlab-runner register --machine-name "auto-scaled-%s" ...) are not saved to
config.tomlfile more clean after runner's registration. Generally it removes parts for non-used executors (which before this MR are present as toml headers for sections with some default values) and marks some kubernetes options with
Why was this MR needed?
- Makes registration more usable for scripting and adds support for missing options. 2. Is a nice, non-critical improvement
Are there points in the code the reviewer needs to double check?
KubernetesConfig fields should be really set to
omitempty and which not? I don't have any experience with Kubernetes so I chosen this guided by a hunch.
Does this MR meet the acceptance criteria?
- Documentation created/updated
- Added for this feature/bug
- All builds are passing
Branch has no merge conflicts with
master(if you do - rebase it please)
What are the relevant issue numbers?
Fixes #1802 (closed)