Kubernetes node selector questions
I can't understand how the kubernetes node selector table should be expressed, the configuration says:
node_selector: A table of key=value pairs of string=string. Setting this limits the creation of pods to kubernetes nodes matching all the key=value pairs
Then i find the following example:
[runners.kubernetes.node_selector]
gitlab = "true"
image_pull_secrets = ["docker-registry-credentials"]
Then reading the toml documentation about tables (https://github.com/toml-lang/toml#table), they say:
[table-1]
key1 = "some string"
key2 = 123
[table-2]
key1 = "another string"
key2 = 456
Now, my doubts:
- What does represent the
gitlab = "true"
? A pair of key=value ? - If
[runners.kubernetes.node_selector]
is a table of node key=value node selectors, why we findimage_pull_secrets
there ? - Taking for example, this set of labels of google gke cluster:
Labels: beta.kubernetes.io/arch=amd64
beta.kubernetes.io/instance-type=n1-standard-1
beta.kubernetes.io/os=linux
cloud.google.com/gke-nodepool=default-pool
failure-domain.beta.kubernetes.io/region=europe-west1
How they should be represented in a valid toml ?
- Is this node selector also valid for the auto-deploy image https://gitlab.com/gitlab-examples/kubernetes-deploy/blob/master/deploy ? Just looking at this file, i would say no.
Thanks a lot!