No description
Find a file
2021-11-08 12:21:00 +01:00
implementation first running kustomize version 2021-11-08 12:21:00 +01:00
manifests first running kustomize version 2021-11-08 12:21:00 +01:00
Readme.md first running kustomize version 2021-11-08 12:21:00 +01:00

PostgreSQL Container in OKD / OpenShift 4

Here's an example for an postgresql container running in OKD / OpenShift and kubernetes.

Goals:

  • use the original alpine image (modern and no CVE's)
  • use a CI/CDD deployment which allows multiple instances in one namespace
  • use kustomize with layers
  • run it secure

start

Run kustomize build implementation | kubectl apply -f - or kustomize build implementation | oc apply -f - on OKD/OCP.

customize

The complete customizations is in the folder manifests.

  • append the stagename to every applicatin (you can include other dependencies in the dev/test/qm/prod kustomize layers)
  • prepend with application name

At this point there's only the database in the base dir. But you can add your application as additional dir in base. There you have the variable $(POSTGRESQL_SERVICE_HOST) you can use in your deployment. This is the servicename for the postgreSQL service.


peter pfläging pete@pflaeging.net