Fix permissions on /run/systemd/nspawn/locks
authorSeth Jennings <sjenning@redhat.com>
Tue, 5 May 2015 18:31:01 +0000 (13:31 -0500)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Wed, 6 May 2015 02:21:26 +0000 (22:21 -0400)
commit7e7cddb22493642dad826ec42ac00979f40b2d17
tree7fcf384fe8354ae784d39c17d0000c3cc023d0e4
parente5f270f5d09a97c5ad603636add7f16ac216e10a
Fix permissions on /run/systemd/nspawn/locks

machined is getting an EACCES when trying to create the lock file for
images because the mode on /run/systemd/nspawn/locks is 0600.

mkdir("/run/systemd/nspawn/locks", 0600) = -1 EEXIST (File exists)
stat("/run/systemd/nspawn/locks", {st_mode=S_IFDIR|0600, st_size=40, ...}) = 0
open("/run/systemd/nspawn/locks/inode-41:256", O_RDWR|O_CREAT|O_NOCTTY|O_NOFOLLOW|O_CLOEXEC, 0600) = -1 EACCES (Permission denied)

This commit adjusts the mode to 0700 to correct the issue.
src/shared/machine-image.c