Add labels to resources
Last updated on
A label is a key-value pair. You can assign labels to a resource when you create it or add them later. Not all resources support labels yet. For an overview of the supported resources, see Resource labelling. For the allowed characters, reserved keys, and limits, see Label format.
To add labels while you create a resource:
- In the Labels section of the order form, click Add Label.
- Enter a key and a value.
- Repeat these steps for each additional label.
To add labels to an existing resource:
- Open the overview page of the resource.
- In the Labels section, click the pencil icon.
- Click Add Label.
- Enter a key and a value.
- Save your changes.
When you create or modify a resource with the API or Terraform, you can add a map of key-value pairs as labels. For example, see the IaaS API or the Terraform Provider for servers.
If you create a server through the API, in addition to other fields you can add:
..."labels": { "team": "compliant-coders", "department": "IT", "product-id": "hello-world-app"},...To remove a label with the API, set its value to null.
Next steps
Section titled “Next steps”Labels assigned to a resource appear in the tag column of your FOCUS report. For more information, see Labels in your FOCUS report.