Jackie Huang | e0634c6 | 2022-05-05 19:49:22 +0800 | [diff] [blame] | 1 | require ha-common.inc |
| 2 | SUBPATH0 = "service-mgmt-api/sm-api" |
| 3 | |
| 4 | LICENSE = "Apache-2.0" |
| 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" |
| 6 | |
| 7 | RDEPENDS_${PN}_append = " \ |
| 8 | bash \ |
| 9 | python-six \ |
| 10 | chkconfig \ |
| 11 | mtce-pmon \ |
| 12 | " |
| 13 | inherit setuptools |
| 14 | SYSTEMD_PACKAGES += "sm-api" |
| 15 | SYSTEMD_SERVICE_sm-api = "sm-api.service" |
| 16 | SYSTEMD_AUTO_ENABLE_sm-api = "enable" |
| 17 | |
| 18 | do_install_append () { |
| 19 | install -d -m 0755 ${D}/${sysconfdir}/sm |
| 20 | install -d -m 0755 ${D}/${sysconfdir}/init.d |
| 21 | install -d -m 0755 ${D}/${sysconfdir}/pmon.d |
| 22 | install -d -m 0755 ${D}/${sysconfdir}/sm-api |
| 23 | install -d -m 0755 ${D}/${systemd_system_unitdir} |
| 24 | install -m 644 scripts/sm_api.ini ${D}/${sysconfdir}/sm |
| 25 | install -m 755 scripts/sm-api ${D}/${sysconfdir}/init.d |
| 26 | install -m 644 scripts/sm-api.service ${D}/${systemd_system_unitdir} |
| 27 | install -m 644 scripts/sm-api.conf ${D}/${sysconfdir}/pmon.d |
| 28 | install -m 644 etc/sm-api/policy.json ${D}/${sysconfdir}/sm-api |
| 29 | } |