issue-14: structure kubernetes
All checks were successful
Cadoles/hydra-sql/pipeline/pr-develop This commit looks good
All checks were successful
Cadoles/hydra-sql/pipeline/pr-develop This commit looks good
This commit is contained in:
@ -0,0 +1,8 @@
|
||||
---
|
||||
nameReference:
|
||||
- kind: Secret
|
||||
fieldSpecs:
|
||||
- path: spec/superuserSecret/name
|
||||
kind: Cluster
|
||||
- path: spec/bootstrap/initdb/secret/name
|
||||
kind: Cluster
|
@ -0,0 +1,32 @@
|
||||
apiVersion: kustomize.config.k8s.io/v1alpha1
|
||||
kind: Component
|
||||
|
||||
generatorOptions:
|
||||
disableNameSuffixHash: true
|
||||
|
||||
configurations:
|
||||
- ./configurations/cnpg-cluster.yaml
|
||||
|
||||
resources:
|
||||
- ./resources/hydra-sql-cnpg-cluster.yaml
|
||||
|
||||
secretgenerator:
|
||||
- name: hydra-sql-postgres-admin
|
||||
type: secret
|
||||
literals:
|
||||
- username=postgres
|
||||
- password=notsosecret
|
||||
- name: hydra-sql-postgres-user
|
||||
type: Secret
|
||||
literals:
|
||||
- username=hydra-sql
|
||||
- password=NotSoSecretButThisIsBad
|
||||
|
||||
vars:
|
||||
- name: APP_DATABASE_SERVICE_NAME
|
||||
objref:
|
||||
name: hydra-sql-postgres
|
||||
kind: Cluster
|
||||
apiVersion: postgresql.cnpg.io/v1
|
||||
fieldref:
|
||||
fieldpath: metadata.name
|
@ -0,0 +1,17 @@
|
||||
apiVersion: postgresql.cnpg.io/v1
|
||||
kind: Cluster
|
||||
metadata:
|
||||
name: hydra-sql-postgres
|
||||
spec:
|
||||
instances: 3
|
||||
primaryUpdateStrategy: unsupervised
|
||||
superuserSecret:
|
||||
name: hydra-sql-postgres-admin
|
||||
bootstrap:
|
||||
initdb:
|
||||
database: hydra-sql
|
||||
owner: hydra-sql
|
||||
secret:
|
||||
name: hydra-sql-postgres-user
|
||||
storage:
|
||||
size: 20Gi
|
Reference in New Issue
Block a user