diff options
| -rw-r--r-- | grumpy/gitsnapshot/gitsnapshot-cronjob.yaml | 2 | ||||
| -rw-r--r-- | grumpy/gitsnapshot/kustomization.yaml | 7 | ||||
| -rw-r--r-- | grumpy/static-files/base/kustomization.yaml | 21 | ||||
| -rw-r--r-- | grumpy/static-files/base/static-files-deploy.yaml | 14 | ||||
| -rw-r--r-- | grumpy/static-files/base/static-files-ing.yaml | 17 | ||||
| -rw-r--r-- | grumpy/static-files/base/static-files-svc.yaml | 6 | ||||
| -rw-r--r-- | grumpy/static-files/blog/ingress.yaml | 8 | ||||
| -rw-r--r-- | grumpy/static-files/blog/kustomization.yaml | 23 | ||||
| -rw-r--r-- | grumpy/static-files/photos/kustomization.yaml | 20 |
9 files changed, 77 insertions, 41 deletions
diff --git a/grumpy/gitsnapshot/gitsnapshot-cronjob.yaml b/grumpy/gitsnapshot/gitsnapshot-cronjob.yaml index 5dbe5ee..2a90f9a 100644 --- a/grumpy/gitsnapshot/gitsnapshot-cronjob.yaml +++ b/grumpy/gitsnapshot/gitsnapshot-cronjob.yaml @@ -33,7 +33,7 @@ spec: secretKeyRef: key: AWS_ACCESS_KEY_ID name: aws-s3-secret - image: registry.gitlab.com/grumps/grumpy-containers/git-snapshot:v0.0.4 + image: registry.gitlab.com/grumps/grumpy-containers/git-snapshot:latest imagePullPolicy: Always name: gitsnapshot volumeMounts: diff --git a/grumpy/gitsnapshot/kustomization.yaml b/grumpy/gitsnapshot/kustomization.yaml index 8ed81eb..5dec50c 100644 --- a/grumpy/gitsnapshot/kustomization.yaml +++ b/grumpy/gitsnapshot/kustomization.yaml @@ -7,7 +7,6 @@ commonLabels: # Images modify the tags for images without # creating patches. images: -- name: busybox - name: registry.gitlab.com/grumps/grumpy-containers/git-snapshot newTag: latest @@ -19,9 +18,3 @@ namePrefix: gitsnapshot # and emits as a YAML string resources: - gitsnapshot-cronjob.yaml - -# Each entry in this list results in the creation of -# one Secret resource (it's a generator of n secrets). -secretGenerator: -- name: aws-s3-secret - type: Opaque diff --git a/grumpy/static-files/base/kustomization.yaml b/grumpy/static-files/base/kustomization.yaml index 6d1eee5..8884ed5 100644 --- a/grumpy/static-files/base/kustomization.yaml +++ b/grumpy/static-files/base/kustomization.yaml @@ -1,19 +1,3 @@ -# Labels to add to all resources and selectors. -commonLabels: - app.kubernetes.io/instance: static-files - app.kubernetes.io/name: static-files - app.kubernetes.io/version: "1.0" - -# Images modify the tags for images without -# creating patches. -images: -- name: static-files - newName: registry.gitlab.com/grumps/ofmax/prod - newTag: latest - -# Value of this field is prepended to the -# names of all resources -namePrefix: static-files # List of resource files that kustomize reads, modifies # and emits as a YAML string @@ -21,5 +5,10 @@ resources: - static-files-deploy.yaml - static-files-ing.yaml - static-files-svc.yaml + # - middleware.yaml + + # configurations: + # - nameReference.yaml + apiVersion: kustomize.config.k8s.io/v1beta1 kind: Kustomization diff --git a/grumpy/static-files/base/static-files-deploy.yaml b/grumpy/static-files/base/static-files-deploy.yaml index f89e7d7..993c6e4 100644 --- a/grumpy/static-files/base/static-files-deploy.yaml +++ b/grumpy/static-files/base/static-files-deploy.yaml @@ -2,25 +2,27 @@ apiVersion: apps/v1 kind: Deployment metadata: name: static-files + labels: + app.kubernetes.io/part-of: static-files + app.kubernetes.io/version: "1.0" spec: replicas: 1 selector: matchLabels: - app.kubernetes.io/instance: static-files - app.kubernetes.io/name: static-files + app.kubernetes.io/part-of: static-files template: metadata: labels: - app.kubernetes.io/instance: static-files - app.kubernetes.io/name: static-files + app.kubernetes.io/part-of: static-files + app.kubernetes.io/version: "1.0" spec: containers: - - image: static-files + - image: web livenessProbe: httpGet: path: / port: http - name: static-files + name: web ports: - containerPort: 8080 name: http diff --git a/grumpy/static-files/base/static-files-ing.yaml b/grumpy/static-files/base/static-files-ing.yaml index f0f05eb..9dee43b 100644 --- a/grumpy/static-files/base/static-files-ing.yaml +++ b/grumpy/static-files/base/static-files-ing.yaml @@ -5,24 +5,23 @@ metadata: certmanager.k8s.io/cluseterissuer: letsencrypt-prod ingress.kubernetes.io/ssl-redirect: "true" kubernetes.io/ingress.class: traefik - traefik.ingress.kubernetes.io/frontend-entry-points: http,https - traefik.ingress.kubernetes.io/redirect-entry-point: https - traefik.ingress.kubernetes.io/redirect-permanent: "true" - name: blog + name: static-files + labels: + app.kubernetes.io/part-of: static-files + app.kubernetes.io/version: "1.0" spec: rules: - - host: ofmax.li + - host: host http: paths: - backend: service: - name: blog + name: static-files port: number: 8080 pathType: Prefix path: / tls: - hosts: - - www.ofmax.li - - ofmax.li - secretName: ofmax-li-sec + - host + secretName: prod-ofmax-li-sec diff --git a/grumpy/static-files/base/static-files-svc.yaml b/grumpy/static-files/base/static-files-svc.yaml index 8096a60..f169a75 100644 --- a/grumpy/static-files/base/static-files-svc.yaml +++ b/grumpy/static-files/base/static-files-svc.yaml @@ -2,6 +2,9 @@ apiVersion: v1 kind: Service metadata: name: static-files + labels: + app.kubernetes.io/part-of: static-files + app.kubernetes.io/version: "1.0" spec: ports: - name: http @@ -9,6 +12,5 @@ spec: protocol: TCP targetPort: http selector: - app.kubernetes.io/instance: static-files - app.kubernetes.io/name: static-files + app.kubernetes.io/part-of: static-files type: ClusterIP diff --git a/grumpy/static-files/blog/ingress.yaml b/grumpy/static-files/blog/ingress.yaml new file mode 100644 index 0000000..fc60d92 --- /dev/null +++ b/grumpy/static-files/blog/ingress.yaml @@ -0,0 +1,8 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: static-files +spec: + rules: + - $patch: merge + host: stuff diff --git a/grumpy/static-files/blog/kustomization.yaml b/grumpy/static-files/blog/kustomization.yaml new file mode 100644 index 0000000..44f580e --- /dev/null +++ b/grumpy/static-files/blog/kustomization.yaml @@ -0,0 +1,23 @@ +resources: + - ../base +namePrefix: blog- +commonLabels: + app.kubernetes.io/name: blog +patches: + - target: + kind: Ingress + name: static-files + patch: |- + - op: replace + path: /spec/rules/0/host + value: ofmax.li + - op: replace + path: /spec/tls/0/hosts/0 + value: ofmax.li + - op: add + path: /spec/tls/0/hosts/- + value: www.ofmax.li +images: +- name: web + newName: registry.gitlab.com/grumps/ofmax/prod + newTag: v0.0.1 diff --git a/grumpy/static-files/photos/kustomization.yaml b/grumpy/static-files/photos/kustomization.yaml new file mode 100644 index 0000000..a9b88aa --- /dev/null +++ b/grumpy/static-files/photos/kustomization.yaml @@ -0,0 +1,20 @@ +resources: +- ../base +namePrefix: photos- +commonLabels: + app.kubernetes.io/name: photos +patches: +- target: + kind: Ingress + name: static-files + patch: |- + - op: replace + path: /spec/rules/0/host + value: photos.ofmax.li + - op: replace + path: /spec/tls/0/hosts/0 + value: photos.ofmax.li +images: +- name: web + newName: registry.gitlab.com/grumps/photos.ofmax.li/prod + newTag: v0.0.2 |