diff --git a/roles/tower/templates/tower_postgres.yaml.j2 b/roles/tower/templates/tower_postgres.yaml.j2 index a58f21e9..a82ac803 100644 --- a/roles/tower/templates/tower_postgres.yaml.j2 +++ b/roles/tower/templates/tower_postgres.yaml.j2 @@ -53,6 +53,10 @@ spec: volumeClaimTemplates: - metadata: name: postgres +{% if tower_postgres_storage_class is defined %} + annotations: + volume.beta.kubernetes.io/storage-class: '{{ tower_postgres_storage_class }}' +{% endif %} spec: accessModes: - ReadWriteOnce