{"action":"created","issue":{"url":"https://api.github.com/repos/saltstack/salt/issues/34945","repository_url":"https://api.github.com/repos/saltstack/salt","labels_url":"https://api.github.com/repos/saltstack/salt/issues/34945/labels{/name}","comments_url":"https://api.github.com/repos/saltstack/salt/issues/34945/comments","events_url":"https://api.github.com/repos/saltstack/salt/issues/34945/events","html_url":"https://github.com/saltstack/salt/issues/34945","id":167556382,"number":34945,"title":"file.recurse breaks directory permissions","user":{"login":"babilen","id":117961,"avatar_url":"https://avatars.githubusercontent.com/u/117961?v=3","gravatar_id":"","url":"https://api.github.com/users/babilen","html_url":"https://github.com/babilen","followers_url":"https://api.github.com/users/babilen/followers","following_url":"https://api.github.com/users/babilen/following{/other_user}","gists_url":"https://api.github.com/users/babilen/gists{/gist_id}","starred_url":"https://api.github.com/users/babilen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/babilen/subscriptions","organizations_url":"https://api.github.com/users/babilen/orgs","repos_url":"https://api.github.com/users/babilen/repos","events_url":"https://api.github.com/users/babilen/events{/privacy}","received_events_url":"https://api.github.com/users/babilen/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/saltstack/salt/labels/2015.8.12","name":"2015.8.12","color":"fbca04"},{"url":"https://api.github.com/repos/saltstack/salt/labels/2016.3.3","name":"2016.3.3","color":"fbca04"},{"url":"https://api.github.com/repos/saltstack/salt/labels/Bug","name":"Bug","color":"e11d21"},{"url":"https://api.github.com/repos/saltstack/salt/labels/State%20Module","name":"State Module","color":"006b75"},{"url":"https://api.github.com/repos/saltstack/salt/labels/TEAM%20Core","name":"TEAM Core","color":"A9A9A9"}],"state":"open","locked":false,"assignee":{"login":"terminalmage","id":328598,"avatar_url":"https://avatars.githubusercontent.com/u/328598?v=3","gravatar_id":"","url":"https://api.github.com/users/terminalmage","html_url":"https://github.com/terminalmage","followers_url":"https://api.github.com/users/terminalmage/followers","following_url":"https://api.github.com/users/terminalmage/following{/other_user}","gists_url":"https://api.github.com/users/terminalmage/gists{/gist_id}","starred_url":"https://api.github.com/users/terminalmage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/terminalmage/subscriptions","organizations_url":"https://api.github.com/users/terminalmage/orgs","repos_url":"https://api.github.com/users/terminalmage/repos","events_url":"https://api.github.com/users/terminalmage/events{/privacy}","received_events_url":"https://api.github.com/users/terminalmage/received_events","type":"User","site_admin":false},"assignees":[{"login":"terminalmage","id":328598,"avatar_url":"https://avatars.githubusercontent.com/u/328598?v=3","gravatar_id":"","url":"https://api.github.com/users/terminalmage","html_url":"https://github.com/terminalmage","followers_url":"https://api.github.com/users/terminalmage/followers","following_url":"https://api.github.com/users/terminalmage/following{/other_user}","gists_url":"https://api.github.com/users/terminalmage/gists{/gist_id}","starred_url":"https://api.github.com/users/terminalmage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/terminalmage/subscriptions","organizations_url":"https://api.github.com/users/terminalmage/orgs","repos_url":"https://api.github.com/users/terminalmage/repos","events_url":"https://api.github.com/users/terminalmage/events{/privacy}","received_events_url":"https://api.github.com/users/terminalmage/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/saltstack/salt/milestones/89","html_url":"https://github.com/saltstack/salt/milestones/C%205","labels_url":"https://api.github.com/repos/saltstack/salt/milestones/89/labels","id":1897763,"number":89,"title":"C 5","description":"","creator":{"login":"meggiebot","id":12242451,"avatar_url":"https://avatars.githubusercontent.com/u/12242451?v=3","gravatar_id":"","url":"https://api.github.com/users/meggiebot","html_url":"https://github.com/meggiebot","followers_url":"https://api.github.com/users/meggiebot/followers","following_url":"https://api.github.com/users/meggiebot/following{/other_user}","gists_url":"https://api.github.com/users/meggiebot/gists{/gist_id}","starred_url":"https://api.github.com/users/meggiebot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/meggiebot/subscriptions","organizations_url":"https://api.github.com/users/meggiebot/orgs","repos_url":"https://api.github.com/users/meggiebot/repos","events_url":"https://api.github.com/users/meggiebot/events{/privacy}","received_events_url":"https://api.github.com/users/meggiebot/received_events","type":"User","site_admin":false},"open_issues":23,"closed_issues":3,"state":"open","created_at":"2016-07-21T22:34:47Z","updated_at":"2016-08-09T17:45:29Z","due_on":"2016-08-26T06:00:00Z","closed_at":null},"comments":16,"created_at":"2016-07-26T09:05:01Z","updated_at":"2016-08-09T17:56:10Z","closed_at":null,"body":"### Description of Issue/Question\r\n\r\nA normal `file.recurse` state results in broken permissions of the managed directory.\r\n\r\n### Steps to Reproduce Issue\r\n\r\nUse a state such as:\r\n\r\n```\r\n/home/foo/.hooks:\r\n  file.recurse:\r\n    - source: salt://users/files/hooks\r\n    - user: foo\r\n    - group: foo\r\n    - dir_mode: 2755\r\n    - file_mode: 755\r\n```\r\nwhich creates the following directory:\r\n\r\n```\r\n/home/foo# ls -lah\r\ntotal 32K\r\ndrwxr-x--- 5 foo foo 4.0K Jul 26 09:00 .\r\ndrwxr-xr-x 4 root  root  4.0K Jul 26 08:59 ..\r\n...\r\ndr-x--xrwt 3 foo foo 4.0K Jul 26 09:00 .hooks\r\n...\r\n```\r\n\r\nI had to add an explicit `file.directory` state for `/home/foo/.hooks` to get correct (and sensible) permissions.\r\n\r\n### Versions Report\r\n```\r\n# salt-minion --versions-report\r\nSalt Version:\r\n           Salt: 2016.3.1\r\n \r\nDependency Versions:\r\n           cffi: 0.8.6\r\n       cherrypy: Not Installed\r\n       dateutil: 2.2\r\n          gitdb: Not Installed\r\n      gitpython: Not Installed\r\n          ioflo: Not Installed\r\n         Jinja2: 2.7.3\r\n        libgit2: Not Installed\r\n        libnacl: Not Installed\r\n       M2Crypto: Not Installed\r\n           Mako: Not Installed\r\n   msgpack-pure: Not Installed\r\n msgpack-python: 0.4.2\r\n   mysql-python: 1.2.3\r\n      pycparser: 2.10\r\n       pycrypto: 2.6.1\r\n         pygit2: Not Installed\r\n         Python: 2.7.9 (default, Mar  1 2015, 12:57:24)\r\n   python-gnupg: Not Installed\r\n         PyYAML: 3.11\r\n          PyZMQ: 14.4.0\r\n           RAET: Not Installed\r\n          smmap: Not Installed\r\n        timelib: Not Installed\r\n        Tornado: 4.2.1\r\n            ZMQ: 4.0.5\r\n \r\nSystem Versions:\r\n           dist: debian 8.5 \r\n        machine: x86_64\r\n        release: 3.16.0-4-amd64\r\n         system: Linux\r\n        version: debian 8.5\r\n\r\n# salt --versions-report\r\nSalt Version:\r\n           Salt: 2016.3.1\r\n \r\nDependency Versions:\r\n           cffi: 0.8.6\r\n       cherrypy: Not Installed\r\n       dateutil: 2.2\r\n          gitdb: 0.5.4\r\n      gitpython: 0.3.2 RC1\r\n          ioflo: Not Installed\r\n         Jinja2: 2.7.3\r\n        libgit2: Not Installed\r\n        libnacl: Not Installed\r\n       M2Crypto: Not Installed\r\n           Mako: Not Installed\r\n   msgpack-pure: Not Installed\r\n msgpack-python: 0.4.2\r\n   mysql-python: 1.2.3\r\n      pycparser: 2.10\r\n       pycrypto: 2.6.1\r\n         pygit2: Not Installed\r\n         Python: 2.7.9 (default, Mar  1 2015, 12:57:24)\r\n   python-gnupg: Not Installed\r\n         PyYAML: 3.11\r\n          PyZMQ: 14.4.0\r\n           RAET: Not Installed\r\n          smmap: 0.8.2\r\n        timelib: Not Installed\r\n        Tornado: 4.2.1\r\n            ZMQ: 4.0.5\r\n \r\nSystem Versions:\r\n           dist: debian 8.5 \r\n        machine: x86_64\r\n        release: 3.16.0-4-amd64\r\n         system: Linux\r\n        version: debian 8.5 \r\n```"},"comment":{"url":"https://api.github.com/repos/saltstack/salt/issues/comments/238635950","html_url":"https://github.com/saltstack/salt/issues/34945#issuecomment-238635950","issue_url":"https://api.github.com/repos/saltstack/salt/issues/34945","id":238635950,"user":{"login":"terminalmage","id":328598,"avatar_url":"https://avatars.githubusercontent.com/u/328598?v=3","gravatar_id":"","url":"https://api.github.com/users/terminalmage","html_url":"https://github.com/terminalmage","followers_url":"https://api.github.com/users/terminalmage/followers","following_url":"https://api.github.com/users/terminalmage/following{/other_user}","gists_url":"https://api.github.com/users/terminalmage/gists{/gist_id}","starred_url":"https://api.github.com/users/terminalmage/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/terminalmage/subscriptions","organizations_url":"https://api.github.com/users/terminalmage/orgs","repos_url":"https://api.github.com/users/terminalmage/repos","events_url":"https://api.github.com/users/terminalmage/events{/privacy}","received_events_url":"https://api.github.com/users/terminalmage/received_events","type":"User","site_admin":false},"created_at":"2016-08-09T17:56:10Z","updated_at":"2016-08-09T17:56:10Z","body":"Fixed in https://github.com/saltstack/salt/pull/35309, integration test included."}}
{"actor":{"display_login":"terminalmage"}}