Greetings Folks - I'm trying to setup a new defaul...
# kubernetes
n
Greetings Folks - I'm trying to setup a new default StorageClass on a new EKS cluster and I'm trying to find a way to remove the old EKS default of
gp2
with Pulumi. This step is rather important for a lot of my automation in this stack because I don't want volumes on gp2. I didn't see much in terms of best practices. Can I just Delete the storage class? Does that need to be wrapped in some sort of check for subsequent
pulumi up
runs? Any suggestions?
e
You are able to create one with a different type of storage, like
gp3
and make it the default if you wish, by specifying this annotation:
Copy code
storageclass.kubernetes.io/is-default-class: 'true'
when creating the new StorageClass https://www.pulumi.com/registry/packages/kubernetes/api-docs/storage/v1/storageclass/
n
I have done that, but the issue is that then there are two defaults. Also I do not want users to have access to gp2 storage, hence trying to delete it.
s
EKS creates the storage class separately from Pulumi. Because of this, Pulumi's state is not aware of it so you are free to delete it however you want