Skip to content
Open
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
14 changes: 11 additions & 3 deletions ghost/ghost-app/deployment-ghost.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ metadata:
spec:
replicas: 1
strategy:
type: Recreate
type: RollingUpdate
template:
spec:
securityContext:
Expand All @@ -23,8 +23,6 @@ spec:
env:
- name: BITNAMI_DEBUG
value: "true"
- name: ALLOW_EMPTY_PASSWORD
value: "yes"
- name: GHOST_DATABASE_HOST
value: mariadb
- name: GHOST_DATABASE_PORT_NUMBER
Expand All @@ -33,12 +31,22 @@ spec:
value: bitnami_ghost
- name: GHOST_DATABASE_USER
value: bn_ghost
- name: GHOST_DATABASE_PASSWORD
valueFrom:
secretKeyRef:
name: mariadb
key: mysql-password
- name: GHOST_HOST
value: example.com
- name: GHOST_PORT_NUMBER
value: "2368"
- name: GHOST_USERNAME
value: user
- name: GHOST_PASSWORD
valueFrom:
secretKeyRef:
name: ghost-app
key: ghost-password
- name: GHOST_EMAIL
value: [email protected]
- name: GHOST_BLOG_TITLE
Expand Down
19 changes: 19 additions & 0 deletions ghost/ghost-app/externalsecret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: ghost-app
namespace: example
labels:
app.kubernetes.io/name: ghost-app
spec:
refreshInterval: 1h # rate SecretManager pulls GCPSM
secretStoreRef:
kind: ClusterSecretStore
name: gcp-secret-provider # name of the SecretStore (or kind specified)
target:
name: ghost-app # name of the k8s Secret to be created
creationPolicy: Owner
dataFrom:
- extract:
key: blog-credentials # name of the GCPSM secret key
version: "2"
19 changes: 19 additions & 0 deletions ghost/mariadb/externalsecret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: mariadb
namespace: example
labels:
app.kubernetes.io/name: mariadb
spec:
refreshInterval: 1h # rate SecretManager pulls GCPSM
secretStoreRef:
kind: ClusterSecretStore
name: gcp-secret-provider # name of the SecretStore (or kind specified)
target:
name: mariadb # name of the k8s Secret to be created
creationPolicy: Owner
dataFrom:
- extract:
key: blog-db-credentials # name of the GCPSM secret key
version: "1"
12 changes: 10 additions & 2 deletions ghost/mariadb/statefulset-mariadb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,20 @@ spec:
env:
- name: BITNAMI_DEBUG
value: "true"
- name: MARIADB_ROOT_PASSWORD
valueFrom:
secretKeyRef:
name: mariadb
key: mysql-root-password
- name: MARIADB_PASSWORD
valueFrom:
secretKeyRef:
name: mariadb
key: mysql-password
- name: MARIADB_USER
value: bn_ghost
- name: MARIADB_DATABASE
value: bitnami_ghost
- name: ALLOW_EMPTY_PASSWORD
value: "true"
ports:
- name: mysql
containerPort: 3306
Expand Down