{"action":"created","issue":{"url":"https://api.github.com/repos/minishift/minishift/issues/2932","repository_url":"https://api.github.com/repos/minishift/minishift","labels_url":"https://api.github.com/repos/minishift/minishift/issues/2932/labels{/name}","comments_url":"https://api.github.com/repos/minishift/minishift/issues/2932/comments","events_url":"https://api.github.com/repos/minishift/minishift/issues/2932/events","html_url":"https://github.com/minishift/minishift/issues/2932","id":373540234,"node_id":"MDU6SXNzdWUzNzM1NDAyMzQ=","number":2932,"title":"Mount error (SELinux) when running `buildah` inside a `knative/build`","user":{"login":"vdemeester","id":6508,"node_id":"MDQ6VXNlcjY1MDg=","avatar_url":"https://avatars0.githubusercontent.com/u/6508?v=4","gravatar_id":"","url":"https://api.github.com/users/vdemeester","html_url":"https://github.com/vdemeester","followers_url":"https://api.github.com/users/vdemeester/followers","following_url":"https://api.github.com/users/vdemeester/following{/other_user}","gists_url":"https://api.github.com/users/vdemeester/gists{/gist_id}","starred_url":"https://api.github.com/users/vdemeester/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vdemeester/subscriptions","organizations_url":"https://api.github.com/users/vdemeester/orgs","repos_url":"https://api.github.com/users/vdemeester/repos","events_url":"https://api.github.com/users/vdemeester/events{/privacy}","received_events_url":"https://api.github.com/users/vdemeester/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-10-24T15:23:18Z","updated_at":"2018-10-25T07:17:47Z","closed_at":null,"author_association":"NONE","body":"### General information\r\n\r\n  * Minishift version: 1.25.0\r\n  * OS: Linux \r\n  * Hypervisor: KVM\r\n\r\n### Steps to reproduce\r\n\r\n  1. Install `knative` on Minishift (see https://github.com/knative/docs/blob/master/install/Knative-with-Minishift.md)\r\n  2. `wget https://raw.githubusercontent.com/vdemeester/ocf-sandbox/master/auth.template.yml -O auth.yaml`, modify it with your login info, `oc apply -f auth.yaml`\r\n  3. `oc apply -f https://raw.githubusercontent.com/vdemeester/ocf-sandbox/master/ocf-230/s2i.template.yaml`\r\n  4. `oc apply -f https://raw.githubusercontent.com/vdemeester/ocf-sandbox/master/ocf-230/s2i.build.yaml`\r\n  5. Wait for the build to fail (at some point)\r\n\r\n### Expected\r\n\r\nBuild success\r\n\r\n### Actual\r\n\r\nThe error would looks like : \r\n\r\n```\r\nerror running subprocess: error bind mounting \"/tmp/buildah019197800/hosts\" from host to \"/etc/hosts\" in mount namespace (\"/tmp/buildah019197800/mnt/rootfs/etc/hosts\"): permission denied\r\n```\r\n\r\nLooking in the `audit` log, we can see `SELinux` is disallowing this mount : \r\n\r\n```\r\ntype=AVC msg=audit(1540386825.073:5158): avc:  denied  { mounton } for  pid=29873 comm=\"exe\" path=\"/tmp/buildah019197800/mnt/rootfs/etc/hosts\" dev=\"sda1\" ino=18575118 scontext=system_u:system_r:container_t:s0:c4,c12 tcontext=system_u:object_r:container_file_t:s0:c4,c12 tclass=file\r\n```\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/minishift/minishift/issues/comments/432941256","html_url":"https://github.com/minishift/minishift/issues/2932#issuecomment-432941256","issue_url":"https://api.github.com/repos/minishift/minishift/issues/2932","id":432941256,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMjk0MTI1Ng==","user":{"login":"vdemeester","id":6508,"node_id":"MDQ6VXNlcjY1MDg=","avatar_url":"https://avatars0.githubusercontent.com/u/6508?v=4","gravatar_id":"","url":"https://api.github.com/users/vdemeester","html_url":"https://github.com/vdemeester","followers_url":"https://api.github.com/users/vdemeester/followers","following_url":"https://api.github.com/users/vdemeester/following{/other_user}","gists_url":"https://api.github.com/users/vdemeester/gists{/gist_id}","starred_url":"https://api.github.com/users/vdemeester/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vdemeester/subscriptions","organizations_url":"https://api.github.com/users/vdemeester/orgs","repos_url":"https://api.github.com/users/vdemeester/repos","events_url":"https://api.github.com/users/vdemeester/events{/privacy}","received_events_url":"https://api.github.com/users/vdemeester/received_events","type":"User","site_admin":false},"created_at":"2018-10-25T07:17:47Z","updated_at":"2018-10-25T07:17:47Z","author_association":"NONE","body":"@praveenkumar oups the formatting ate the audit log 🤣"}}
{"actor":{"display_login":"vdemeester"}}