4
0
Fork 2
mirror of https://gerrit.hackerspace.pl/hscloud synced 2025-02-09 08:06:45 +00:00

app/mastodon: complete migration to versioned postgres

Change-Id: Ib09a42e60cc3bf7a0388b5199a22df6a1271b5a3
Reviewed-on: https://gerrit.hackerspace.pl/c/hscloud/+/1424
Reviewed-by: q3k <q3k@hackerspace.pl>
This commit is contained in:
implr 2022-11-18 23:55:02 +01:00 committed by implr
parent 65b30af78e
commit e3dd96adb0

View file

@ -1,6 +1,5 @@
local kube = import "../../../kube/kube.libsonnet";
local postgres = import "../../../kube/postgres.libsonnet";
local postgres_v = import "../../../kube/postgres_v.libsonnet";
local postgres = import "../../../kube/postgres_v.libsonnet";
local redis = import "../../../kube/redis.libsonnet";
{
@ -117,22 +116,9 @@ local redis = import "../../../kube/redis.libsonnet";
namespace: kube.Namespace(cfg.namespace),
local ns = self.namespace,
# there used to be a nonversioned postgres (10.4) here
# at time of writing it exists in prod, scaled down to 0, to preserve the PVC
postgres: postgres {
cfg+: {
namespace: cfg.namespace,
appName: "mastodon",
database: "mastodon",
username: "mastodon",
prefix: "waw3-",
password: kube.SecretKeyRef(app.config, "postgres-pass"),
storageClassName: "waw-hdd-redundant-3",
storageSize: "100Gi",
opts: { wal_level: "logical" },
},
},
#TODO(implr) remove above and replace with this post migration
postgresNew: postgres_v {
cfg+: {
version: "13.9",
namespace: cfg.namespace,