Skip to content

Commit

Permalink
tetragon-oci-hook: daemonset to uninstall the hook
Browse files Browse the repository at this point in the history
This is mostly for illustration purposes until we find something better.

Signed-off-by: Kornilios Kourtis <kornilios@isovalent.com>
  • Loading branch information
kkourt committed Dec 12, 2023
1 parent 9c435c1 commit 3ee875b
Showing 1 changed file with 49 additions and 0 deletions.
49 changes: 49 additions & 0 deletions contrib/rthooks/tetragon-oci-hook/k8s/ds-uninstall.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: tetragon-oci-hook-uninstall
namespace: kube-system
labels:
k8s-app: tetragon-oci-hook-setup-test
spec:
selector:
matchLabels:
name: tetragon-oci-hook-setup
template:
metadata:
labels:
name: tetragon-oci-hook-setup
spec:
initContainers:
- name: setup
securityContext:
privileged: true
image: localhost/cilium/tetragon:latest
imagePullPolicy: IfNotPresent
command:
- "tetragon-oci-hook-setup"
- "uninstall"
- "--interface=oci-hooks"
- "--local-install-dir=/hostInstall"
- "--oci-hooks.local-dir=/hostHooks"
volumeMounts:
- name: hooks-path
mountPath: /hostHooks
- name: opt-path
mountPath: /hostInstall
containers:
- name: sleep
image: busybox:1.28
command: ['sh', '-c', 'sleep 365d']
volumeMounts:
- name: opt-path
mountPath: /hostInstall
volumes:
- name: hooks-path
hostPath:
path: /usr/share/containers/oci/hooks.d/
type: DirectoryOrCreate
- name: opt-path
hostPath:
path: /opt/tetragon
type: DirectoryOrCreate

0 comments on commit 3ee875b

Please sign in to comment.