blob: 7f71e7c01dfda47253cefb111ece900140ba032c [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"
5LIC_FILES_CHKSUM = "file://${OPENPOWERBASE}/COPYING.apache-2.0;md5=34400b68072d710fecd0a2940a0d1658"
6
7inherit allarch systemd
8
9RDEPENDS_${PN} = "${VIRTUAL-RUNTIME_base-utils}"
10
11SYSTEMD_SERVICE_${PN} = "first-boot-set-hostname.service"
12
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