Skip to content

Commit

Permalink
Update Kustomize resources.
Browse files Browse the repository at this point in the history
  • Loading branch information
ropable committed Dec 10, 2024
1 parent 04b7617 commit 2d32894
Show file tree
Hide file tree
Showing 6 changed files with 87 additions and 95 deletions.
118 changes: 63 additions & 55 deletions kustomize/base/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,67 +2,75 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: mapproxy-deployment
labels:
app: mapproxy-deployment
spec:
selector:
matchLabels:
app: mapproxy-deployment
strategy:
type: RollingUpdate
template:
metadata:
labels:
app: mapproxy-deployment
spec:
containers:
- name: mapproxy
image: ghcr.io/dbca-wa/mapproxy
imagePullPolicy: Always
env:
- name: TZ
value: "Australia/Perth"
resources:
requests:
memory: "150Mi"
cpu: "25m"
limits:
memory: "2Gi"
cpu: "1000m"
startupProbe:
httpGet:
path: /demo/
port: 8080
scheme: HTTP
initialDelaySeconds: 5
periodSeconds: 5
failureThreshold: 3
successThreshold: 1
timeoutSeconds: 3
livenessProbe:
httpGet:
path: /demo/
port: 8080
scheme: HTTP
initialDelaySeconds: 0
periodSeconds: 15
failureThreshold: 3
successThreshold: 1
timeoutSeconds: 3
readinessProbe:
httpGet:
path: /demo/
port: 8080
scheme: HTTP
initialDelaySeconds: 0
periodSeconds: 15
failureThreshold: 3
successThreshold: 1
timeoutSeconds: 3
securityContext:
runAsNonRoot: true
privileged: false
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
volumeMounts:
- name: tmpfs-ram
mountPath: /tmp
subPath: cache_data
- name: mapproxy
image: ghcr.io/dbca-wa/mapproxy
imagePullPolicy: Always
env:
- name: TZ
value: "Australia/Perth"
resources:
requests:
memory: "100Mi"
cpu: "5m"
limits:
memory: "2Gi"
cpu: "1000m"
startupProbe:
httpGet:
path: /demo/
port: 8080
scheme: HTTP
initialDelaySeconds: 5
periodSeconds: 5
failureThreshold: 3
successThreshold: 1
timeoutSeconds: 3
livenessProbe:
httpGet:
path: /demo/
port: 8080
scheme: HTTP
initialDelaySeconds: 0
periodSeconds: 15
failureThreshold: 3
successThreshold: 1
timeoutSeconds: 3
readinessProbe:
httpGet:
path: /demo/
port: 8080
scheme: HTTP
initialDelaySeconds: 0
periodSeconds: 15
failureThreshold: 3
successThreshold: 1
timeoutSeconds: 3
securityContext:
runAsNonRoot: true
privileged: false
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
volumeMounts:
- name: tmpfs-ram
mountPath: /tmp
subPath: cache_data
volumes:
- name: tmpfs-ram
emptyDir:
Expand Down
8 changes: 4 additions & 4 deletions kustomize/base/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ metadata:
spec:
type: ClusterIP
ports:
- name: wsgi
port: 8080
protocol: TCP
targetPort: 8080
- name: wsgi
port: 8080
protocol: TCP
targetPort: 8080
8 changes: 0 additions & 8 deletions kustomize/overlays/prod/deployment_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: mapproxy-deployment
labels:
app: mapproxy-deployment
spec:
selector:
matchLabels:
app: mapproxy-deployment
template:
metadata:
labels:
app: mapproxy-deployment
spec:
containers:
- name: mapproxy
Expand Down
20 changes: 10 additions & 10 deletions kustomize/overlays/prod/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ metadata:
spec:
ingressClassName: nginx
rules:
- host: mapproxy.dbca.wa.gov.au
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: mapproxy-clusterip-prod
port:
number: 8080
- host: mapproxy.dbca.wa.gov.au
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: mapproxy-clusterip-prod
port:
number: 8080
8 changes: 0 additions & 8 deletions kustomize/overlays/uat/deployment_patch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,8 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: mapproxy-deployment
labels:
app: mapproxy-deployment
spec:
selector:
matchLabels:
app: mapproxy-deployment
template:
metadata:
labels:
app: mapproxy-deployment
spec:
containers:
- name: mapproxy
Expand Down
20 changes: 10 additions & 10 deletions kustomize/overlays/uat/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ metadata:
spec:
ingressClassName: nginx
rules:
- host: mapproxy-uat.dbca.wa.gov.au
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: mapproxy-clusterip-uat
port:
number: 8080
- host: mapproxy-uat.dbca.wa.gov.au
http:
paths:
- path: /
pathType: Prefix
backend:
service:
name: mapproxy-clusterip-uat
port:
number: 8080

0 comments on commit 2d32894

Please sign in to comment.