Files
vrpmdv-yocto-recipes/recipes-vrpmdv/recipes-base/python3-gunicorn/python3-gunicorn_%.bbappend

36 lines
1.2 KiB
Plaintext

SUMMARY = "Install and start a systemd services"
SECTION = "mlgunicorn"
LICENSE = "CLOSED"
inherit systemd
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
SRC_URI += "file://vrpmdv_web.service"
SRC_URI += "file://vrpmdv_web.socket"
SYSTEMD_AUTO_ENABLE = "enable"
SYSTEMD_SERVICE:${PN} = "vrpmdv_web.service vrpmdv_web.socket "
FILES:${PN} += "${systemd_system_unitdir}"
FILES:${PN} += "${systemd_system_unitdir}/vrpmdv_web.service"
FILES:${PN} += "${systemd_system_unitdir}/vrpmdv_web.socket"
do_install:append () {
install -d ${D}/${systemd_system_unitdir}
install -m 0644 ${WORKDIR}/vrpmdv_web.service ${D}/${systemd_system_unitdir}
install -m 0644 ${WORKDIR}/vrpmdv_web.socket ${D}/${systemd_system_unitdir}
install -d ${D}${sysconfdir}/systemd/system/multi-user.target.wants/
install -d ${D}${sysconfdir}/systemd/system/sockets.target.wants/
ln -s ${systemd_system_unitdir}/vrpmdv_web.socket ${D}${sysconfdir}/systemd/system/sockets.target.wants/vrpmdv_web.socket
ln -s ${systemd_system_unitdir}/vrpmdv_web.service ${D}${sysconfdir}/systemd/system/multi-user.target.wants/vrpmdv_web.service
}
REQUIRED_DISTRO_FEATURES= "systemd"