mirror of
https://github.com/puppetmaster/typhoon.git
synced 2024-12-26 04:09:34 +01:00
5eb4078d68
* Annotate pods, deployments, and daemonsets to start containers with the Docker runtime's default seccomp profile * Overrides Kubernetes default behavior which started containers with seccomp=unconfined * https://docs.docker.com/engine/security/seccomp/#pass-a-profile-for-a-container
43 lines
1.0 KiB
YAML
43 lines
1.0 KiB
YAML
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: default-backend
|
|
namespace: ingress
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
name: default-backend
|
|
phase: prod
|
|
template:
|
|
metadata:
|
|
labels:
|
|
name: default-backend
|
|
phase: prod
|
|
annotations:
|
|
seccomp.security.alpha.kubernetes.io/pod: 'docker/default'
|
|
spec:
|
|
containers:
|
|
- name: default-backend
|
|
# Any image is permissable as long as:
|
|
# 1. It serves a 404 page at /
|
|
# 2. It serves 200 on a /healthz endpoint
|
|
image: k8s.gcr.io/defaultbackend:1.4
|
|
ports:
|
|
- containerPort: 8080
|
|
resources:
|
|
limits:
|
|
cpu: 10m
|
|
memory: 20Mi
|
|
requests:
|
|
cpu: 10m
|
|
memory: 20Mi
|
|
livenessProbe:
|
|
httpGet:
|
|
path: /healthz
|
|
port: 8080
|
|
scheme: HTTP
|
|
initialDelaySeconds: 30
|
|
timeoutSeconds: 5
|
|
terminationGracePeriodSeconds: 60
|