diff mbox series

[meta-swupdate-boards] raspberry: overlayfs: Add the Install section

Message ID 20211122114800.165542-1-festevam@gmail.com
State Accepted
Headers show
Series [meta-swupdate-boards] raspberry: overlayfs: Add the Install section | expand

Commit Message

Fabio Estevam Nov. 22, 2021, 11:48 a.m. UTC
Add the Install section so that the overlays-etc-dirs service
can be automatically started by systemd.

Without the Install section the following warning is seen when
enabling the service manually:

systemctl enable overlays-etc-dirs

The unit files have no installation config (WantedBy=, RequiredBy=, Also=,
Alias= settings in the [Install] section, and DefaultInstance= for template
units). This means they are not meant to be enabled using systemctl.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 .../recipes-core/overlayfs/files/overlays-etc-dirs.service     | 3 +++
 1 file changed, 3 insertions(+)

Comments

Stefano Babic Nov. 22, 2021, 2:17 p.m. UTC | #1
On 22.11.21 12:48, Fabio Estevam wrote:
> Add the Install section so that the overlays-etc-dirs service
> can be automatically started by systemd.
> 
> Without the Install section the following warning is seen when
> enabling the service manually:
> 
> systemctl enable overlays-etc-dirs
> 
> The unit files have no installation config (WantedBy=, RequiredBy=, Also=,
> Alias= settings in the [Install] section, and DefaultInstance= for template
> units). This means they are not meant to be enabled using systemctl.
> 
> Signed-off-by: Fabio Estevam <festevam@gmail.com>
> ---
>   .../recipes-core/overlayfs/files/overlays-etc-dirs.service     | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service b/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service
> index b32418bb495f..7aac30fd0187 100644
> --- a/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service
> +++ b/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service
> @@ -8,3 +8,6 @@ Type=oneshot
>   ExecStart=/bin/mkdir -p /media/overlayfs/etc/upper
>   ExecStart=/bin/mkdir -p /media/overlayfs/etc/work
>   RemainAfterExit=yes
> +
> +[Install]
> +WantedBy=local-fs.target
> 

Applied to -master, thanks !

Best regards,
Stefano Babic
diff mbox series

Patch

diff --git a/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service b/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service
index b32418bb495f..7aac30fd0187 100644
--- a/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service
+++ b/dynamic-layers/raspberrypi/recipes-core/overlayfs/files/overlays-etc-dirs.service
@@ -8,3 +8,6 @@  Type=oneshot
 ExecStart=/bin/mkdir -p /media/overlayfs/etc/upper
 ExecStart=/bin/mkdir -p /media/overlayfs/etc/work
 RemainAfterExit=yes
+
+[Install]
+WantedBy=local-fs.target