A tag is a combination of a key and a value. If a tag with the same key already exists for the specified resource, no new tag is created. Instead, the value of the existing tag is updated. You can also add tags to instances when launching them, and to snapshots when creating them. For more information, see Creating / Launching Instances and Creating a Snapshot of a Volume. To add tags to your load balancers, see Adding or Removing Tags in LBU. |
To add another tag to the resource, click and enter a key and a value.
The tag value is optional. You can add a tag by specifying a key only. |
To remove a tag, click .
Click Ok to validate.
The tags are added to or removed from the selected resource.
You can update the key or value of existing tags at any time. To do so, select the resource and click Tags |
To add one or more tags, use the create-tags command following this syntax:
$ aws ec2 create-tags \ --profile YOUR_PROFILE \ --resources sg-12345678 i-12345678\ --tags Key=Name,Value=SG1 Key=Name2,Value=I1 \ --endpoint https://fcu.eu-west-2.outscale.com |
resources:
The ID of one or more resources to which you want to add the tag. For more information, see About Tags > Resource Types.
If you specify several resources, each tag is added to each one of them. |
tags
: The tags you want to add to the specified resources. This attribute contains the following elements that you need to specify for each tag:key
: The key of the tag.value
: The value of the tag.
If you want to specify a key only, you can set the |
The specified tags are added to the specified resources.
To remove one or more tags, use the delete-tags command following this syntax:
$ aws ec2 delete-tags \ --profile YOUR_PROFILE \ --resources sg-12345678 i-12345678 \ --tags Key=Name,Value=SG1 Key=Name2,Value=I1 \ --endpoint https://fcu.eu-west-2.outscale.com |
resources
: The ID of one or more resources from which you want to remove the specified tags.
If you specify several resources, the tags are removed from all of them. |
tags
: The tags you want to delete from the specified resources. This attribute contains the following elements that you need to specify for each tag:key
: The key of the tag.
(optional) value
: The value of the tag.
- If you do not specify any value, all tags with the same key are removed from the specified resource. - If you set the value as an empty string, the tag is removed only if its value is set to an empty string. |
The specified tags are removed from the specified resources.