commit | 2e78e09b2b0888d03ea2ed5e30f56c3b66545fa8 | [log] [tgz] |
---|---|---|
author | Alexander Filippov <a.filippov@yadro.com> | Fri Oct 18 15:10:30 2019 +0300 |
committer | Brad Bishop <bradleyb@fuzziesquirrel.com> | Mon Oct 21 08:09:45 2019 -0400 |
tree | a0e89fb414cadb9f6db838032dc1f88242d0901b | |
parent | 11afa3b7f379bd5da37ab755ebf140f8aa724ef2 [diff] |
first-boot-set-*: Use ConditionPathExists Replaces the calls of `systemctl disable` with `ConditionPathExists=' in the systemd units files. It will allow us to distinguish an admin created state and a runtime created state. (From meta-openpower rev: 4b5603b4426442973f29392ee4d0955f48680fac) Change-Id: I1d187662576dea93550d21cf7031fbc663610fe7 Signed-off-by: Alexander Filippov <a.filippov@yadro.com> Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
diff --git a/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac.sh b/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac.sh index da1b305..63a4ad7 100755 --- a/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac.sh +++ b/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac.sh
@@ -79,4 +79,6 @@ sync_mac $1 -systemctl --no-reload disable first-boot-set-mac@${1}.service +# Prevent start at next boot time +mkdir -p "/var/lib/first-boot-set-mac" +touch "/var/lib/first-boot-set-mac/${1}"
diff --git a/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac@.service b/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac@.service index 8986efd..3ff5fc1 100644 --- a/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac@.service +++ b/meta-openpower/recipes-phosphor/network/first-boot-set-mac/first-boot-set-mac@.service
@@ -1,5 +1,6 @@ [Unit] Description=Init BMC MAC address for NIC %I +ConditionPathExists=!/var/lib/first-boot-set-mac/%i Wants=mapper-wait@-xyz-openbmc_project-inventory.service After=mapper-wait@-xyz-openbmc_project-inventory.service Wants=mapper-wait@-xyz-openbmc_project-network-%i.service