diff --git a/applications/redis.yaml b/applications/redis.yaml index 2f5b6ed8..92a84cba 100644 --- a/applications/redis.yaml +++ b/applications/redis.yaml @@ -9,10 +9,8 @@ spec: elements: - cluster: https://kubernetes.default.svc env: prod - hostname: redis.srv.oceanbox.io - cluster: https://kubernetes.default.svc env: staging - hostname: redis.beta.oceanbox.io template: metadata: name: '{{ env }}-redis' @@ -22,25 +20,13 @@ spec: server: https://kubernetes.default.svc namespace: redis sources: - # - repoURL: https://charts.bitnami.com/bitnami - # targetRevision: 18.9.1 - # chart: redis - # helm: - # valueFiles: - # - $values/redis/values.yaml - # - repoURL: https://gitlab.com/oceanbox/manifests.git - # targetRevision: HEAD - # path: kustomizations/redis/{{ env }} - # ref: values + - repoURL: https://charts.bitnami.com/bitnami + targetRevision: 19.5.2 + chart: redis + helm: + valueFiles: + - $values/redis/values-{{ env }}.yaml - repoURL: https://gitlab.com/oceanbox/manifests.git - targetRevision: main + targetRevision: HEAD path: kustomizations/redis - plugin: - name: kustomize-helm-with-rewrite - parameters: - - name: env - string: '{{ env }}' - - name: hostname - string: '{{ hostname }}' - - name: chart - string: bitnami/redis + ref: values diff --git a/kustomizations/redis/base/kustomization.yaml b/kustomizations/redis/base/kustomization.yaml deleted file mode 100644 index 0637caf9..00000000 --- a/kustomizations/redis/base/kustomization.yaml +++ /dev/null @@ -1,4 +0,0 @@ -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization -resources: -- _manifest.yaml diff --git a/kustomizations/redis/chart b/kustomizations/redis/chart deleted file mode 100644 index 5ff67ce7..00000000 --- a/kustomizations/redis/chart +++ /dev/null @@ -1 +0,0 @@ -bitnami/redis diff --git a/kustomizations/redis/prod/kustomization.yaml b/kustomizations/redis/prod/kustomization.yaml deleted file mode 100644 index 5462b99f..00000000 --- a/kustomizations/redis/prod/kustomization.yaml +++ /dev/null @@ -1,5 +0,0 @@ -apiVersion: kustomize.config.k8s.io/v1beta1 -kind: Kustomization -resources: -- nodeport.yaml -- ../base diff --git a/kustomizations/redis/prod/nodeport.yaml b/kustomizations/redis/prod/nodeport.yaml deleted file mode 100644 index e65efac6..00000000 --- a/kustomizations/redis/prod/nodeport.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: prod-redis-nodeport -spec: - externalTrafficPolicy: Cluster - ports: - - name: redis - nodePort: 30379 - port: 6379 - protocol: TCP - targetPort: 6379 - selector: - app.kubernetes.io/instance: prod-redis - app.kubernetes.io/name: redis - sessionAffinity: None - type: NodePort diff --git a/kustomizations/redis/staging/kustomization.yaml b/kustomizations/redis/staging/kustomization.yaml deleted file mode 100644 index 7746caed..00000000 --- a/kustomizations/redis/staging/kustomization.yaml +++ /dev/null @@ -1,3 +0,0 @@ -resources: -- nodeport.yaml -- ../base diff --git a/kustomizations/redis/staging/nodeport.yaml b/kustomizations/redis/staging/nodeport.yaml deleted file mode 100644 index fe0b1d74..00000000 --- a/kustomizations/redis/staging/nodeport.yaml +++ /dev/null @@ -1,17 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: staging-redis-nodeport -spec: - externalTrafficPolicy: Cluster - ports: - - name: redis - nodePort: 31379 - port: 6379 - protocol: TCP - targetPort: 6379 - selector: - app.kubernetes.io/instance: staging-redis - app.kubernetes.io/name: redis - sessionAffinity: None - type: NodePort diff --git a/kustomizations/redis/values-prod.yaml b/kustomizations/redis/values-prod.yaml index 5ef3cf49..383caf99 100644 --- a/kustomizations/redis/values-prod.yaml +++ b/kustomizations/redis/values-prod.yaml @@ -1,5 +1,13 @@ -replica: - replicaCount: 2 +architecture: replication + auth: + enabled: true + sentinel: true + password: "" + usePasswordFiles: false + existingSecretPasswordKey: "" existingSecret: prod-redis +service: + nodePorts: + redis: 30379 diff --git a/kustomizations/redis/values-staging.yaml b/kustomizations/redis/values-staging.yaml index fa905197..47414e38 100644 --- a/kustomizations/redis/values-staging.yaml +++ b/kustomizations/redis/values-staging.yaml @@ -1,5 +1,17 @@ +architechture: standalone + replica: - replicaCount: 2 + replicaCount: 1 + auth: + enabled: true + sentinel: true + password: "" + usePasswordFiles: false + existingSecretPasswordKey: "" existingSecret: staging-redis +service: + nodePorts: + redis: 31379 + diff --git a/kustomizations/redis/values.yaml b/kustomizations/redis/values.yaml deleted file mode 100644 index f7bc7f49..00000000 --- a/kustomizations/redis/values.yaml +++ /dev/null @@ -1,9 +0,0 @@ -architecture: replication -auth: - enabled: true - sentinel: true - password: "" - existingSecret: "" - existingSecretPasswordKey: "" - usePasswordFiles: false -