Skip to content

Commit

Permalink
Add gp3 storageclass
Browse files Browse the repository at this point in the history
We add this unconditionally to all clusters for simplification,
so we can set storageClass: gp3 for new clusters that come up on
AWS without issue. This doesn't change the default, and does not
change the storageclass in existing clusters. In addition to using
gp3, it also sets reclaimPolicy to Retain, so if the PVC is deleted,
it does not delete the PV or the underlying EBS volume.

Ref 2i2c-org#2906
Ref 2i2c-org#2717
  • Loading branch information
yuvipanda committed Aug 7, 2023
1 parent 71afd5a commit b1fb570
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions helm-charts/support/templates/storageclass/gp3.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
name: gp3
# Use the AWS EBS CSI provisioner
provisioner: ebs.csi.aws.com
parameters:
# gp3 is cheaper than gp2
type: gp3
fsType: ext4
# Do not delete the underlying EBS volume whenever this PV & PVC
# are deleted! This allows us recovery in case of accidental deletion
reclaimPolicy: Retain
# Create the EBS volume only when the pod consuming it tries to use it.
# This ensures the EBS volume is created in the correct *zone*, so we
# don't end up with issues where the volume is in a different zone (but
# same region) as our pods.
volumeBindingMode: WaitForFirstConsumer
File renamed without changes.

0 comments on commit b1fb570

Please sign in to comment.