jenkins-bot has submitted this change and it was merged.
Change subject: Only mount /vagrant/logs if not using NFS
......................................................................
Only mount /vagrant/logs if not using NFS
The NFS configuration exports the vagrant root directory with user
mapping enabled. This allows the guest to mount the directory and write
to it using any user while the host sees the files as owned by the
configured map user.
Change-Id: Ic3e2620d259b4a81fee59b51e676c80f131b02fc
---
M Vagrantfile
1 file changed, 14 insertions(+), 12 deletions(-)
Approvals:
Dduvall: Looks good to me, but someone else must approve
Manybubbles: Looks good to me, but someone else must approve
MaxSem: Looks good to me, approved
jenkins-bot: Verified
diff --git a/Vagrantfile b/Vagrantfile
index 00a28d0..666cc24 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -91,18 +91,20 @@
config.vm.synced_folder '.', '/vagrant', root_share_options
- # www-data needs to write to the logs, but doesn't need write
- # access for all of /vagrant
- #
- # TODO (mattflaschen, 2014-05-23): It should also be possible to
- # use NFS for this (the web server writes to it). I tried to do
- # this by putting map_uid and map_gid as 33 (www-data) on the guest,
- # but it didn't work. Although the export file looks right the
- # effective permissions on the guest were still the same as /vagrant.
- config.vm.synced_folder './logs', '/vagrant/logs',
- id: 'vagrant-logs',
- owner: 'www-data',
- group: 'www-data'
+ if !settings[:nfs_shares]
+ # www-data needs to write to the logs, but doesn't need write
+ # access for all of /vagrant
+ #
+ # Users of NFS should not need this special export because of the
+ # global uid/gid map used for the NFS export. Attempts from within the
+ # VM to chmod files and folders to www-data:www-data will fail
+ # however, so avoid that in puppet code and account for it in shell
+ # scripts.
+ config.vm.synced_folder './logs', '/vagrant/logs',
+ id: 'vagrant-logs',
+ owner: 'www-data',
+ group: 'www-data'
+ end
config.vm.provider :virtualbox do |vb|
# See http://www.virtualbox.org/manual/ch08.html for additional
options.
--
To view, visit https://gerrit.wikimedia.org/r/156230
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ic3e2620d259b4a81fee59b51e676c80f131b02fc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/vagrant
Gerrit-Branch: master
Gerrit-Owner: BryanDavis <[email protected]>
Gerrit-Reviewer: BryanDavis <[email protected]>
Gerrit-Reviewer: Dduvall <[email protected]>
Gerrit-Reviewer: Manybubbles <[email protected]>
Gerrit-Reviewer: Mattflaschen <[email protected]>
Gerrit-Reviewer: MaxSem <[email protected]>
Gerrit-Reviewer: Ori.livneh <[email protected]>
Gerrit-Reviewer: Yurik <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits