From d2736102f3b32306e3d0edb9584548ad9a967881 Mon Sep 17 00:00:00 2001 From: Muhammad Shakeel Date: Fri, 27 Sep 2013 18:14:15 +0000 Subject: opkg: Use systemd service for first boot configuration Currently opkg uses a script to configure packages during first time boot. This script is present in rcS.d and when 'sysvinit' is disabled this script doesn't execute. For systemd only distros this newly added service will run the opkg configure during first boot only. (From OE-Core rev: fdcfcea5b8eae1769a217f8efea9c02f037f63fa) Signed-off-by: Muhammad Shakeel Signed-off-by: Saul Wold Signed-off-by: Richard Purdie --- meta/recipes-devtools/opkg/opkg/opkg-configure.service | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 meta/recipes-devtools/opkg/opkg/opkg-configure.service (limited to 'meta/recipes-devtools/opkg/opkg') diff --git a/meta/recipes-devtools/opkg/opkg/opkg-configure.service b/meta/recipes-devtools/opkg/opkg/opkg-configure.service new file mode 100644 index 0000000000..a1c3a31796 --- /dev/null +++ b/meta/recipes-devtools/opkg/opkg/opkg-configure.service @@ -0,0 +1,17 @@ +[Unit] +Description=Opkg first boot configure +DefaultDependencies=no +After=systemd-remount-fs.service systemd-tmpfiles-setup.service tmp.mount +Before=sysinit.target + +[Service] +Type=oneshot +EnvironmentFile=-@SYSCONFDIR@/default/postinst +ExecStart=@BASE_BINDIR@/sh -c " if [ $POSTINST_LOGGING = '1' ]; then @BINDIR@/opkg-cl configure > $LOGFILE 2>&1; else @BINDIR@/opkg-cl configure; fi" +ExecStartPost=@BASE_BINDIR@/systemctl disable opkg-configure.service +StandardOutput=syslog +RemainAfterExit=No + +[Install] +WantedBy=basic.target +WantedBy=sysinit.target -- cgit v1.2.3-54-g00ecf