fix(common): correctly disable host docker-compose (#1964)

* fix(common): correctly disable host docker-compose

* whoopsies
This commit is contained in:
Kjeld Schouten-Lebbing
2022-02-25 15:18:50 +01:00
committed by GitHub
parent 236c63dc81
commit d5b90e7d20
3 changed files with 36 additions and 2 deletions
+1 -1
View File
@@ -15,4 +15,4 @@ maintainers:
name: common name: common
sources: null sources: null
type: library type: library
version: 8.17.0 version: 8.17.1
@@ -1,6 +1,7 @@
{{/* {{/*
This template serves as the blueprint for the mountPermissions job that is run This template serves as the blueprint for the mountPermissions job that is run
before chart installation. before chart installation.
TODO: delete docker compose deletion once iX has disabled it
*/}} */}}
{{- define "common.controller.hostpatch" -}} {{- define "common.controller.hostpatch" -}}
- name: hostpatch - name: hostpatch
@@ -11,5 +12,10 @@ before chart installation.
command: command:
- "/bin/sh" - "/bin/sh"
- "-c" - "-c"
- ( sysctl -w fs.inotify.max_user_watches=524288 || echo "error setting inotify") && ( sysctl -w fs.inotify.max_user_instances=512 || echo "error setting inotify")&& ( chmod -x /usr/bin/docker-compose || echo "error locking docker-compose") && ( chmod -x /bin/docker-compose || echo "error locking docker-compose" ) - ( sysctl -w fs.inotify.max_user_watches=524288 || echo "error setting inotify") && ( sysctl -w fs.inotify.max_user_instances=512 || echo "error setting inotify") && ( chmod -x /host/usr/bin/docker-compose || echo "error locking docker-compose") && ( chmod -x /host/usr/bin/docker-compose || echo "error locking docker-compose")
volumeMounts:
- mountPath: /host/usr/bin
name: host-usr-bin
- mountPath: /host/bin
name: host-bin
{{- end -}} {{- end -}}
+28
View File
@@ -741,6 +741,34 @@ persistence:
sizeLimit: # 1Gi sizeLimit: # 1Gi
# -- Hostpath mountpoint to allow mounting the /usr/bin folder to disable docker-compose
# [[ref]]https://kubernetes.io/docs/concepts/storage/volumes/#hostpath)
# @default -- See below
# TODO Delete this once iX has blocked docker-compose
host-usr-bin:
enabled: true
noMount: true
type: hostPath
# -- Which path on the host should be mounted.
hostPath: /usr/bin
# -- Where to mount the path in the main container.
# Defaults to the value of `hostPath`
mountPath: "/host/usr/bin"
# -- Hostpath mountpoint to allow mounting the /bin folder to disable docker-compose
# [[ref]]https://kubernetes.io/docs/concepts/storage/volumes/#hostpath)
# @default -- See below
# TODO Delete this once iX has blocked docker-compose
host-bin:
enabled: true
noMount: true
type: hostPath
# -- Which path on the host should be mounted.
hostPath: /bin
# -- Where to mount the path in the main container.
# Defaults to the value of `hostPath`
mountPath: "/host/bin"
# -- Example of a hostPath mount # -- Example of a hostPath mount
# [[ref]]https://kubernetes.io/docs/concepts/storage/volumes/#hostpath) # [[ref]]https://kubernetes.io/docs/concepts/storage/volumes/#hostpath)
# @default -- See below # @default -- See below