Browse Source

Merge pull request #7466 from mrunalp/fix_docker_selinux

Automatic merge from submit-queue.

crio: Fixup docker SELinux permissions

@rhatdan @sdodson @ashcrow  PTAL
Signed-off-by: Mrunal Patel <mrunalp@gmail.com>
OpenShift Merge Robot 7 years ago
parent
commit
b694841e31
1 changed files with 5 additions and 0 deletions
  1. 5 0
      roles/container_runtime/tasks/package_crio.yml

+ 5 - 0
roles/container_runtime/tasks/package_crio.yml

@@ -69,6 +69,11 @@
     dest: /etc/sysconfig/crio-network
     src: crio-network.j2
 
+- name: Fixup SELinux permissions for docker
+  shell: |
+          semanage fcontext -a -e /var/lib/docker/overlay2 /var/lib/containers/overlay2
+          restorecon -R -v /var/lib/containers/overlay2
+
 - name: Start the CRI-O service
   systemd:
     name: "cri-o"