From a8392da2a24d991553c043446d23ab91c76243bc Mon Sep 17 00:00:00 2001 From: SeanOMik Date: Thu, 17 Oct 2024 15:27:32 -0400 Subject: [PATCH] chore: move fireflyiii to volsync PVCs --- .../fireflyiii/{ => app}/daily-cronjob.yaml | 0 .../fireflyiii/{ => app}/env-secret.sops.yaml | 0 .../fireflyiii/{ => app}/helm-release.yaml | 5 ++- .../fireflyiii/{ => app}/kustomization.yaml | 1 + .../main/apps/default/fireflyiii/ks.yaml | 32 +++++++++++++++++++ .../main/apps/default/kustomization.yaml | 2 +- 6 files changed, 36 insertions(+), 4 deletions(-) rename kubernetes/main/apps/default/fireflyiii/{ => app}/daily-cronjob.yaml (100%) rename kubernetes/main/apps/default/fireflyiii/{ => app}/env-secret.sops.yaml (100%) rename kubernetes/main/apps/default/fireflyiii/{ => app}/helm-release.yaml (93%) rename kubernetes/main/apps/default/fireflyiii/{ => app}/kustomization.yaml (65%) create mode 100644 kubernetes/main/apps/default/fireflyiii/ks.yaml diff --git a/kubernetes/main/apps/default/fireflyiii/daily-cronjob.yaml b/kubernetes/main/apps/default/fireflyiii/app/daily-cronjob.yaml similarity index 100% rename from kubernetes/main/apps/default/fireflyiii/daily-cronjob.yaml rename to kubernetes/main/apps/default/fireflyiii/app/daily-cronjob.yaml diff --git a/kubernetes/main/apps/default/fireflyiii/env-secret.sops.yaml b/kubernetes/main/apps/default/fireflyiii/app/env-secret.sops.yaml similarity index 100% rename from kubernetes/main/apps/default/fireflyiii/env-secret.sops.yaml rename to kubernetes/main/apps/default/fireflyiii/app/env-secret.sops.yaml diff --git a/kubernetes/main/apps/default/fireflyiii/helm-release.yaml b/kubernetes/main/apps/default/fireflyiii/app/helm-release.yaml similarity index 93% rename from kubernetes/main/apps/default/fireflyiii/helm-release.yaml rename to kubernetes/main/apps/default/fireflyiii/app/helm-release.yaml index 92d0c1f..38ec097 100644 --- a/kubernetes/main/apps/default/fireflyiii/helm-release.yaml +++ b/kubernetes/main/apps/default/fireflyiii/app/helm-release.yaml @@ -60,8 +60,7 @@ spec: port: http persistence: - firefly-uploads: - type: hostPath - hostPath: /mnt/MainPool/Kubernetes/fireflyiii-uploads + uploads: + existingClaim: fireflyiii globalMounts: - path: /var/www/html/storage/upload diff --git a/kubernetes/main/apps/default/fireflyiii/kustomization.yaml b/kubernetes/main/apps/default/fireflyiii/app/kustomization.yaml similarity index 65% rename from kubernetes/main/apps/default/fireflyiii/kustomization.yaml rename to kubernetes/main/apps/default/fireflyiii/app/kustomization.yaml index fe2987e..de37026 100644 --- a/kubernetes/main/apps/default/fireflyiii/kustomization.yaml +++ b/kubernetes/main/apps/default/fireflyiii/app/kustomization.yaml @@ -1,6 +1,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization resources: +- ../../../../../common/templates/volsync - ./env-secret.sops.yaml - ./helm-release.yaml - ./daily-cronjob.yaml \ No newline at end of file diff --git a/kubernetes/main/apps/default/fireflyiii/ks.yaml b/kubernetes/main/apps/default/fireflyiii/ks.yaml new file mode 100644 index 0000000..2d40139 --- /dev/null +++ b/kubernetes/main/apps/default/fireflyiii/ks.yaml @@ -0,0 +1,32 @@ +# yaml-language-server: $schema=https://kubernetes-schemas.pages.dev/kustomize.toolkit.fluxcd.io/kustomization_v1.json +apiVersion: kustomize.toolkit.fluxcd.io/v1 +kind: Kustomization +metadata: + name: &app fireflyiii + namespace: flux-system +spec: + timeout: 5m + interval: 10m + targetNamespace: default + path: ./kubernetes/main/apps/default/fireflyiii/app + prune: true + sourceRef: + kind: GitRepository + name: home-cluster + decryption: + provider: sops + secretRef: + name: sops-gpg + dependsOn: + - name: openebs + - name: openebs-sc + - name: volsync + postBuild: + substituteFrom: + - kind: ConfigMap + name: cluster-settings + - kind: Secret + name: cluster-secrets + substitute: + APP: *app + VOLSYNC_CAPACITY: 5Gi \ No newline at end of file diff --git a/kubernetes/main/apps/default/kustomization.yaml b/kubernetes/main/apps/default/kustomization.yaml index 2c28fd4..c8df715 100644 --- a/kubernetes/main/apps/default/kustomization.yaml +++ b/kubernetes/main/apps/default/kustomization.yaml @@ -1,7 +1,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization resources: -- ./fireflyiii +- ./fireflyiii/ks.yaml - ./cdn - ./trilium - ./mealie