Extra mounts must be mounted in major version upgrade init container
Summary
When an extension that require extra mounts is installed in a cluster and we perform a major version upgrade. The operation might fail due to missing extra mounts in the init container that run the pg_upgrade
command.
DISCLAIMER: This bug has not been produced but we left the hypothetical steps that should manifest it. If the behavior is different or is not a bug, please, change the issue description.
Current Behaviour
The upgrade operation failed.
Steps to reproduce
- Create a cluster with postgis extension using lower major version of postgres
- Create some objects that requires proj library like following:
CREATE MATERIALIZED VIEW test AS
SELECT 'mpoint_7', ST_AsEWKT(ST_GeomFromGML('<gml:MultiPoint srsName="EPSG:27582"><gml:pointMember><gml:Point><gml:coordinates>1,2</gml:coordinates></gml:Point></gml:pointMember><gml:pointMember><gml:Point srsName="EPSG:27562"><gml:coordinates>400000,5000000</gml:coordinates></gml:Point></gml:pointMember></gml:MultiPoint>'));
- Set cluster's postgres version to next major version
- Perform a major version upgrade on the cluster using default parameters
Expected Behaviour
The upgrade operation is performed successfully
Possible Solution
Add all extension extra mounts for both source and target postgres versions to major version upgrade init container.
Environment
- StackGres version: 1.0.0-alpha2
- Kubernetes version: ?
- Cloud provider or hardware configuration: ?
Relevant logs and/or screenshots
N/A
Edited by Matteo Melli