{"action":"closed","issue":{"url":"https://api.github.com/repos/geerlingguy/drupal-vm/issues/880","repository_url":"https://api.github.com/repos/geerlingguy/drupal-vm","labels_url":"https://api.github.com/repos/geerlingguy/drupal-vm/issues/880/labels{/name}","comments_url":"https://api.github.com/repos/geerlingguy/drupal-vm/issues/880/comments","events_url":"https://api.github.com/repos/geerlingguy/drupal-vm/issues/880/events","html_url":"https://github.com/geerlingguy/drupal-vm/issues/880","id":172906695,"number":880,"title":"Cannot write to file via post_provision_scripts","user":{"login":"reekris","id":1775259,"avatar_url":"https://avatars.githubusercontent.com/u/1775259?v=3","gravatar_id":"","url":"https://api.github.com/users/reekris","html_url":"https://github.com/reekris","followers_url":"https://api.github.com/users/reekris/followers","following_url":"https://api.github.com/users/reekris/following{/other_user}","gists_url":"https://api.github.com/users/reekris/gists{/gist_id}","starred_url":"https://api.github.com/users/reekris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/reekris/subscriptions","organizations_url":"https://api.github.com/users/reekris/orgs","repos_url":"https://api.github.com/users/reekris/repos","events_url":"https://api.github.com/users/reekris/events{/privacy}","received_events_url":"https://api.github.com/users/reekris/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-08-24T09:34:02Z","updated_at":"2016-08-24T12:25:14Z","closed_at":"2016-08-24T12:25:14Z","body":"After provisioning my box I want to add the path of my composer vendor/bin dir which contains local versions of Drupal Console and Drush downloaded via composer. \r\n\r\nTo do this I have the following in my config.yml:\r\n```\r\npost_provision_scripts:\r\n  - \"{{ config_dir }}/../scripts/vagrant-post-provision.sh\"\r\n```\r\n\r\nMy vagrant-post-provision.sh looks like this:\r\n\r\n```\r\n#!/bin/bash\r\n\r\n# Add local Drush and Drupal Console to PATH\r\nif ! grep -q /var/www/site/vendor/bin \"$HOME/.profile\" ; then\r\n  sudo echo \"export PATH=/var/www/site/vendor/bin:$PATH\" >> $HOME/.profile\r\nelse\r\n  exit 0\r\nfi\r\n```\r\nI don't get any errors while provisioning and it runs the task according to the console output.\r\nHowever my ~/.profile file does not change.\r\n\r\nIf I manually do `vagrant ssh` and run the command\r\n `sh /var/www/site/scripts/vagrant-post-provision.sh`\r\n\r\nIt adds a row to my ~/.profile as expected. \r\n\r\nAny idea what I might be doing wrong?\r\n"}}
{"actor":{"display_login":"reekris"}}