Skip to content

Commit

Permalink
Update hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
jaronoff97 committed Aug 14, 2024
1 parent 309d885 commit 20bb6a3
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/kube-stack-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
kubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.6.1/cert-manager.yaml
kubectl wait --timeout=5m --for=condition=available deployment cert-manager -n cert-manager
kubectl wait --timeout=5m --for=condition=available deployment cert-manager-webhook -n cert-manager
kubectl create ns oks-test
- name: Run chart-testing (install)
run: ct install --charts charts/opentelemetry-kube-stack --namespace oks-test
run: ct install --charts charts/opentelemetry-kube-stack --namespace oks-test --build-id ""
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,16 @@ apiVersion: v1
kind: ServiceAccount
metadata:
name: delete-resources-sa
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
---
# Source: opentelemetry-kube-stack/templates/hooks.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: delete-resources-role
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
rules:
- apiGroups:
- opentelemetry.io
Expand All @@ -27,6 +31,8 @@ apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: delete-resources-rolebinding
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,16 @@ apiVersion: v1
kind: ServiceAccount
metadata:
name: delete-resources-sa
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
---
# Source: opentelemetry-kube-stack/templates/hooks.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: delete-resources-role
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
rules:
- apiGroups:
- opentelemetry.io
Expand All @@ -27,6 +31,8 @@ apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: delete-resources-rolebinding
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
Expand Down
7 changes: 7 additions & 0 deletions charts/opentelemetry-kube-stack/templates/hooks.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
{{- if .Values.cleanupJob.enabled }}
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: delete-resources-sa
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
---
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: delete-resources-role
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
rules:
- apiGroups:
- opentelemetry.io
Expand All @@ -24,6 +29,8 @@ apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
name: delete-resources-rolebinding
annotations:
"helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
Expand Down

0 comments on commit 20bb6a3

Please sign in to comment.