Skip to content

Commit f449a29

Browse files
committed
portable: Don't fail if /etc/resolv.conf doesn't exist
The portable profiles assume /etc/resolv.conf exists, which isn't always the case. Let's mark the mounts as optional so we don't fail to start the unit if /etc/resolv.conf doesn't exist.
1 parent cf5e1b5 commit f449a29

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/portable/profile/default/service.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
MountAPIVFS=yes
55
BindReadOnlyPaths=/dev/log /run/systemd/journal/socket /run/systemd/journal/stdout
66
BindReadOnlyPaths=/etc/machine-id
7-
BindReadOnlyPaths=/etc/resolv.conf
7+
BindReadOnlyPaths=-/etc/resolv.conf
88
BindReadOnlyPaths=/run/dbus/system_bus_socket
99
DynamicUser=yes
1010
RemoveIPC=yes

src/portable/profile/trusted/service.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ MountAPIVFS=yes
55
PrivateTmp=yes
66
BindPaths=/run
77
BindReadOnlyPaths=/etc/machine-id
8-
BindReadOnlyPaths=/etc/resolv.conf
8+
BindReadOnlyPaths=-/etc/resolv.conf

0 commit comments

Comments
 (0)