Skip to content

Commit

Permalink
Tweak Kustomize definitions.
Browse files Browse the repository at this point in the history
  • Loading branch information
ropable committed Dec 7, 2023
1 parent 4bae762 commit 23a4694
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.env
config.yaml
mapproxy.yaml
.python-version
__pycache__/
4 changes: 2 additions & 2 deletions kustomize/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Declarative management of MapProxy Kubernetes resources using Kustomize.

# How to use

Within an overlay directory, create a `config.yaml` file to configure the
Within an overlay directory, create a `mapproxy.yaml` file to configure the
proxied tile layers.

Review the built resource output using `kustomize`:
Expand All @@ -16,7 +16,7 @@ kustomize build kustomize/overlays/uat/ | less
Run `kubectl` with the `-k` flag to generate resources for a given overlay:

```bash
kubectl apply -k kustomize/overlays/uat --namespace sss --dry-run=client
kubectl apply -k kustomize/overlays/uat --namespace mapproxy --dry-run=client
```

# References:
Expand Down
11 changes: 10 additions & 1 deletion kustomize/base/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ spec:
spec:
containers:
- name: mapproxy
image: ghcr.io/dbca-wa/mapproxy
imagePullPolicy: Always
env:
- name: TZ
value: "Australia/Perth"
Expand Down Expand Up @@ -47,5 +49,12 @@ spec:
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
readOnlyRootFilesystem: true
volumeMounts:
- mountPath: /tmp
name: tmpfs-ram
volumes:
- name: tmpfs-ram
emptyDir:
medium: "Memory"
restartPolicy: Always
4 changes: 2 additions & 2 deletions kustomize/base/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
resources:
- deployment.yaml
- service.yaml
- deployment.yaml
- service.yaml
2 changes: 0 additions & 2 deletions kustomize/overlays/uat/deployment_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ spec:
spec:
containers:
- name: mapproxy
image: ghcr.io/dbca-wa/mapproxy
imagePullPolicy: Always
volumeMounts:
- mountPath: /app/config
name: mapproxy-configmap
Expand Down
2 changes: 1 addition & 1 deletion kustomize/overlays/uat/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ patches:
configMapGenerator:
- name: mapproxy-configmap
files:
- config.yaml
- mapproxy.yaml

0 comments on commit 23a4694

Please sign in to comment.