You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Installing with Helm charts shows the following permission issues:
chmod: /var/lib/influxdb2: Operation not permitted
chmod: /var/lib/influxdb2: Operation not permitted
chmod: /etc/influxdb2: Operation not permitted
....
Error: **setup succeeded, but failed to write new config to local path**: open /etc/influxdb2/influx-configs: permission denied
2022-10-14T14:21:33. warn cleaning bolt and engine files to prevent conflicts on retry {"system": "docker", "bolt_path": "/var/lib/influxdb2/influxd.bolt", "engine_path": "/var/lib/influxdb2"}
By default, OpenShift Container Platform runs containers using an arbitrarily assigned user ID. This provides additional security against processes escaping the container due to a container engine vulnerability and thereby achieving escalated permissions on the host node.
For an image to support running as an arbitrary user, directories and files that may be written to by processes in the image should be owned by the root group and be read/writable by that group. Files to be executed should also have group execute permissions.
Adding the following to your Dockerfile sets the directory and file permissions to allow users in the root group to access them in the built image:
I was able to get around this one by creating a new scc and adding the service account to it. You will need to change the line user line to reflect your deployment. The service account should match your helm deployment name but to confirm you can use # oc get serviceaccount
uid1000.yaml
kind: SecurityContextConstraintsapiVersion: security.openshift.io/v1metadata:
annotations:
kubernetes.io/description: Only for things that like UID 1000name: uid1000allowHostDirVolumePlugin: falseallowHostIPC: falseallowHostNetwork: falseallowHostPID: falseallowHostPorts: falseallowPrivilegeEscalation: trueallowPrivilegedContainer: falseallowedCapabilities: nulldefaultAddCapabilities: nullfsGroup:
type: RunAsAnypriority: 10readOnlyRootFilesystem: falserequiredDropCapabilities:
- MKNOD
- KILL
- SYS_CHROOT
- SETUID
- SETGIDrunAsUser:
type: MustRunAsuid: 1000seLinuxContext:
type: MustRunAssupplementalGroups:
type: RunAsAnyusers:
####### Change the line below to reflect your deployment#####
- system:serviceaccount:< project/namespace >:< service account >volumes:
- configMap
- downwardAPI
- emptyDir
- persistentVolumeClaim
- projected
- secret
Then you will have to run the scc in # oc create -f uid1000.yaml
Trash the existing pod to pick up the new scc.
Installing with Helm charts shows the following permission issues:
Here https://docs.openshift.com/container-platform/4.2/openshift_images/create-images.html#images-create-guide-openshift_create-images:
The text was updated successfully, but these errors were encountered: