Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tags on Fabric pool in GCP #196

Open
bryanheo opened this issue May 17, 2024 · 1 comment
Open

Tags on Fabric pool in GCP #196

bryanheo opened this issue May 17, 2024 · 1 comment

Comments

@bryanheo
Copy link

Hello

We are using netapp-cloudmanager_cvo_gcp resources to deploy NetApp CVO in GCP and we are trying to check the cost based on the tags but I cannot see tag option for Google Cloud Storage (Fabric pool).
Could you answer the following questions?

  1. Could you let me know whether we can tag on Fabric pool via Terraform or not?
  2. If not, could we tag on Google Cloud Storage manually?
  3. If we tag on Google Cloud Storage manually, does it affect on the system or Terraform code?

Regards

@suhasbshekar
Copy link
Collaborator

Question 1: Can we tag on Fabric Pool via Terraform?

As of my last update, Terraform's NetApp Cloud Manager provider does not explicitly support tagging Google Cloud Storage buckets used as Fabric Pools directly through the Terraform configuration for CVO deployments. Fabric Pools are utilized within NetApp CVO to tier cold data to Google Cloud Storage, but the management of tags directly through Terraform for these specific resources isn't provided out-of-the-box.

Question 2: Can we tag on Google Cloud Storage manually?

Yes, you can apply tags manually to Google Cloud Storage buckets through the Google Cloud Console or using the gcloud command-line tool.

These tags (also referred to as labels in GCP) can help you with cost allocation and management.
To add a label to a Google Cloud Storage bucket, you can use the following gcloud command:

gcloud storage buckets update [BUCKET_NAME] --update-labels=[KEY]=[VALUE]

Replace [BUCKET_NAME], [KEY], and [VALUE] with your bucket's name and the label key-value pair you wish to apply.

Question 3: If we tag on Google Cloud Storage manually, does it affect the system or Terraform code?

Tagging Google Cloud Storage buckets manually does not directly affect the operation of the system or the Terraform code used to deploy NetApp CVO. However, you should be aware of a few considerations:

State Management: Terraform manages state based on the configuration files and the resources it creates. If you manually add tags to a bucket that Terraform is managing (like those associated with a Fabric Pool), Terraform won’t recognize these changes unless they are imported into its state or reflected in the Terraform configuration. (I need to try in my GCP PoC)
Configuration Drift: Manual changes can lead to configuration drift (As we know ), where the actual state of the environment differs from the state known to Terraform. This can be problematic if Terraform attempts to manage or reconfigure those resources later.

For Best Practice:

If you decide to manually tag resources managed by Terraform, it’s a good practice to consistently manage these tags outside of Terraform to prevent potential configuration conflicts or drift.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants