]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
man: add note about selinux to rc-local
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 17 May 2024 12:31:16 +0000 (14:31 +0200)
committerLuca Boccassi <luca.boccassi@gmail.com>
Fri, 17 May 2024 13:16:07 +0000 (15:16 +0200)
This feature is deprecated, but if users use it, they are likely to be
tripped up by the wrong selinux context, so add a note.

https://discussion.fedoraproject.org/t/systemd-rc-local-service-doesnt-work-on-fedora-40-until-selinux-contexts-are-set-on-rc-local-script

man/systemd-rc-local-generator.xml

index f7f69998b1be90e039810c046e5e6a773ab31df5..cc6068a91e1862a08a6d6d00543f68dc87fb6c6e 100644 (file)
@@ -53,8 +53,8 @@ Wants=network-online.target
 After=network-online.target
 </programlisting>
 
-    <para>Support for <filename>&RC_LOCAL_PATH;</filename> is provided for compatibility with specific System
-    V systems only. However, it is strongly recommended to avoid making use of this script today, and instead
+    <para>Support for <filename>&RC_LOCAL_PATH;</filename> is provided for compatibility with specific
+    System V systems only. However, it is strongly recommended to avoid using this script today, and instead
     provide proper unit files with appropriate dependencies for any scripts to run during the boot process.
     Note that the path to the script is set at compile time and varies between distributions.</para>
 
@@ -62,6 +62,14 @@ After=network-online.target
     <citerefentry><refentrytitle>systemd.generator</refentrytitle><manvolnum>7</manvolnum></citerefentry>.</para>
   </refsect1>
 
+  <refsect1>
+    <title>Notes</title>
+
+    <para>On systems with SELinux, when creating the file, make sure to set the appropriate context, e.g.
+    with "<command>sudo restorecon -v &RC_LOCAL_PATH;</command>".
+    </para>
+  </refsect1>
+
   <refsect1>
     <title>See Also</title>
     <para><simplelist type="inline">