Jump toUpdate content

Managing Tags with the Scaleway Cloud Controller Manager (CCM)

Reviewed on 25 April 2023 • Published on 12 August 2021
Security & Identity (IAM):

You may need certain IAM permissions to carry out some actions described on this page. This means:

  • you are the Owner of the Scaleway Organization in which the actions will be carried out, or
  • you are an IAM user of the Organization, with a policy granting you the necessary permission sets
Requirements:

The Scaleway Cloud Controller Manager (CCM) will also synchronize the tags of Scaleway Instances to Kubernetes Labels on the nodes.

Note:

When using Scaleway’s managed Kubernetes, Kapsule, the tags on the pool will be transformed into tags on the pool’s Instances, so applying to all Kubernetes nodes of the pool.

Labels

In order for a tag to be synced to a label, it needs to be of the form foo=bar. In this case, the Kubernetes nodes will have the label k8s.scaleway.com/foo=bar.

Once the tag is removed from the instance, it will also be removed as a label on the node.

Non prefixed labels

It is possible to add labels not prefixed with k8s.scaleway.com. The downside, is that when you delete the associated tag, the label will not get removed. In order to have non prefixed labels, you should prefix the tag with noprefix=.

For instance the tag noprefix=foo=bar will yield the foo=bar label on the Kubernetes nodes.

This is the only way to add custom prefixed labels like node.kubernetes.io.

Taints

In order for a tag to be synced to a taint, it needs to be of the form taint=foo=bar:Effect, where Effect is one of NoExecute, NoSchedule or PreferNoSchedule. In this case, the Kubernetes nodes will have the taint k8s.scaleway.com/foo=bar with the effect Effect.

Once the tag is removed from the instance, it will also be removed as a taint on the node.

Non prefixed Taints

It is possible to add taints not prefixed with k8s.scaleway.com. The downside, is that when you delete the associated tag, the taint will not get removed. In order to have non prefixed taints, you should prefix the taint with taint=noprefix=.

For instance the tag taint=noprefix=foo=bar:Effect will yield the foo=bar taint on the Kubernetes nodes with the Effect effect.

This is the only way to add custom prefixed taints like node.kubernetes.io.

Special Kubernetes labels

  • node.kubernetes.io/exclude-from-external-load-balancers can be set on the Kubernetes nodes if this same value is set as a tag on the Instance. It will have the value managed-by-scaleway-ccm and will be deleted if deleted from the tags.
See Also