summaryrefslogtreecommitdiffstats
path: root/meta-netboot/recipes-core/systemd/files
diff options
context:
space:
mode:
Diffstat (limited to 'meta-netboot/recipes-core/systemd/files')
-rw-r--r--meta-netboot/recipes-core/systemd/files/resolv-conf-relabel.service14
1 files changed, 14 insertions, 0 deletions
diff --git a/meta-netboot/recipes-core/systemd/files/resolv-conf-relabel.service b/meta-netboot/recipes-core/systemd/files/resolv-conf-relabel.service
new file mode 100644
index 000000000..5d9216cc2
--- /dev/null
+++ b/meta-netboot/recipes-core/systemd/files/resolv-conf-relabel.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=SELinux resolv.conf relabeling
+DefaultDependencies=no
+ConditionKernelCommandLine=ip
+ConditionKernelCommandLine=nbd.server
+After=local-fs.target
+Before=sysinit.target
+
+[Service]
+Type=oneshot
+ExecStart=/usr/sbin/restorecon -Fi /etc/resolv.conf
+
+[Install]
+WantedBy=sysinit.target