Skip to content

Commit

Permalink
WIP: port k8s agent daemonset deployment for mozilla#461
Browse files Browse the repository at this point in the history
  • Loading branch information
jgmize committed Aug 16, 2018
1 parent 2198d56 commit 455a191
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 0 deletions.
9 changes: 9 additions & 0 deletions k8s/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
FROM debian:stretch-slim

ADD mig-agent_20180803-0.e8eb90a.prod_amd64.deb .
#TODO: copy from public s3
RUN dpkg -i mig-agent_20180803-0.e8eb90a.prod_amd64.deb

RUN apt update && apt install -y ca-certificates

CMD ["/sbin/mig-agent", "-f"]
46 changes: 46 additions & 0 deletions k8s/daemonset.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
name: mig-daemon
namespace: mig
spec:
updateStrategy:
type: RollingUpdate
template:
metadata:
labels:
name: mig-ds
spec:
hostPID: true
hostNetwork: true
containers:
- name: mig-agent
image: quay.io/mozmar/mig:8a3f0aaa97dccc808919f7cc561927571980893b
securityContext:
privileged: true
capabilities:
add:
- SYS_PTRACE
volumeMounts:
- name: mig-agent-secrets
mountPath: "/etc/mig"
readOnly: true
- name: root-fs
mountPath: /rootfs
volumes:
- name: root-fs
hostPath:
path: /
- name: mig-agent-secrets
secret:
secretName: "mig-agent-secrets"
items:
- key: agent.crt
path: agent.crt
- key: agent.key
path: agent.key
- key: ca.crt
path: ca.crt
- key: mig-agent.cfg
path: mig-agent.cfg

0 comments on commit 455a191

Please sign in to comment.