blob: 20161bcdc7eec9d7b30990b426214666237fb8a7 [file] [log] [blame]
Alexander Filippov89bd3842019-05-22 11:07:30 +03001SUMMARY = "Init BMC Hostname"
2DESCRIPTION = "Setup BMC Unique hostname"
3PR = "r1"
4LICENSE = "Apache-2.0"
Brad Bishop1ebdb612019-09-13 12:18:25 -04005LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/Apache-2.0;md5=89aea4e17d99a7cacdbeed46a0096b10"
Alexander Filippov89bd3842019-05-22 11:07:30 +03006
7inherit allarch systemd
8
Adriana Kobylak8c6707f2021-08-06 17:35:36 +00009RDEPENDS:${PN} = "${VIRTUAL-RUNTIME_base-utils}"
Alexander Filippov89bd3842019-05-22 11:07:30 +030010
Adriana Kobylak8c6707f2021-08-06 17:35:36 +000011SYSTEMD_SERVICE:${PN} = "first-boot-set-hostname.service"
Alexander Filippov89bd3842019-05-22 11:07:30 +030012
Adriana Kobylakfc7299c2019-08-08 10:30:29 -050013SRC_URI = "file://${BPN}.sh file://${BPN}.service"
Alexander Filippov89bd3842019-05-22 11:07:30 +030014
15S = "${WORKDIR}"
16do_install() {
Adriana Kobylakfc7299c2019-08-08 10:30:29 -050017 sed "s/{MACHINE}/${MACHINE}/" -i ${BPN}.sh
Alexander Filippov89bd3842019-05-22 11:07:30 +030018 install -d ${D}${bindir} ${D}${systemd_system_unitdir}
Adriana Kobylakfc7299c2019-08-08 10:30:29 -050019 install ${BPN}.sh ${D}${bindir}/
20 install -m 644 ${BPN}.service ${D}${systemd_system_unitdir}/
Alexander Filippov89bd3842019-05-22 11:07:30 +030021}
22