cloud-operators icon indicating copy to clipboard operation
cloud-operators copied to clipboard

Add IBM Cloud Tag to managed resources

Open vazirim opened this issue 6 years ago • 2 comments

vazirim avatar Oct 09 '19 20:10 vazirim

One reason I want to use tags is to provide in the IBM Cloud UI (i.e. Resource List) some visibility back to the services.ibmcloud instance that represents it. Recently I saw some services I know I created using the operator, but I have multiple clusters and projects, and could not remember where I created them. Tags are an easy way to provide visibility.

One other thing to consider is creating a resource binding in the resource controller. The resource controller has logic that will prevent a resource (service instance) from being deleted if it has any resource bindings. If the operator were to create a resource binding after it creates the service it can effectively point back to the cluster, project/namespace and instance of services.ibmcloud CRD. That would prevent me from accidentally deleting the service using the IBM Cloud CLI or UI, and force me to do it using the operator.

Here is the publicly available API for the resource controller for creating a resource binding:

Creating a new resource binding

Once created, you can view the resource bindings for a resource instance:

Get all resource bindings for a resource

dwakeman avatar Mar 13 '20 21:03 dwakeman

I think this may be (partially) implemented since I'm seeing some bits about Tags in our types, @vazirim can you confirm?

JohnStarich avatar Aug 21 '20 17:08 JohnStarich