Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config/crd/bases/eda.ansible.com_edas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2389,7 +2389,7 @@ spec:
Default: "prefer"'
type: string
postgres_keep_pvc_after_upgrade:
description: Specify whether or not to keep the old PVC after PostgreSQL upgrades
description: "(Deprecated) Specify whether or not to keep the old PVC after PostgreSQL upgrades"
Comment thread
rooftopcellist marked this conversation as resolved.
type: boolean
storage_requirements:
description: Storage requirements for the PostgreSQL container
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -359,11 +359,6 @@ spec:
path: database.priority_class
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:advanced
- displayName: Should PostgreSQL data for managed databases be kept after upgrades?
path: database.postgres_keep_pvc_after_upgrade
x-descriptors:
- urn:alm:descriptor:com.tectonic.ui:advanced
- urn:alm:descriptor:com.tectonic.ui:booleanSwitch
- displayName: API Image
path: image
x-descriptors:
Expand Down
12 changes: 0 additions & 12 deletions docs/upgrade/upgrading.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,3 @@ Starting with this version, the EDA operator **no longer deploys or uses Redis**
> **Note:** The `redis` fields remain in the CRD schema for backward compatibility but are marked as deprecated. They will be removed in a future `apiVersion`.

For more details, see the [Redis Deprecation Notice](../user-guide/redis-configuration.md).

#### PostgreSQL Upgrade Considerations

If there is a PostgreSQL major version upgrade, after the data directory on the PVC is migrated to the new version, the old PVC is kept by default.
This provides the ability to roll back if needed, but can take up extra storage space in your cluster unnecessarily. By default, the postgres pvc from the previous version will remain unless you manually remove it, or have the `database.postgres_keep_pvc_after_upgrade` parameter set to false. You can configure it to be deleted automatically
after a successful upgrade by setting the following variable on the EDA spec.

```yaml
spec:
database:
postgres_keep_pvc_after_upgrade: false
```
1 change: 0 additions & 1 deletion roles/postgres/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ _database:
tolerations: []
postgres_extra_args: '' # Deprecated
postgres_extra_settings: [] # Define postgresql.conf configurations
postgres_keep_pvc_after_upgrade: true # Specify whether or not to keep the old PVC after PostgreSQL upgrades
postgres_data_volume_init: false
postgres_init_container_commands: |
chown 26:0 /var/lib/pgsql/data
Expand Down
11 changes: 0 additions & 11 deletions roles/postgres/tasks/upgrade_postgres.yml
Original file line number Diff line number Diff line change
Expand Up @@ -168,14 +168,3 @@
loop:
- "{{ ansible_operator_meta.name }}-postgres-13"

- name: Remove old persistent volume claim
k8s:
kind: PersistentVolumeClaim
api_version: v1
namespace: "{{ ansible_operator_meta.namespace }}"
name: "{{ item }}"
state: absent
loop:
- "postgres-{{ ansible_operator_meta.name }}-postgres-13-0"
- "postgres-13-{{ ansible_operator_meta.name }}-postgres-13-0"
when: not combined_database.postgres_keep_pvc_after_upgrade | bool
Loading