-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rest api for control gpio chips Signed-off-by: Sean Nyekjaer <sean.nyekjaer@prevas.dk>
- Loading branch information
1 parent
3d55e0c
commit 1c5a62b
Showing
2 changed files
with
50 additions
and
0 deletions.
There are no files selected for viewing
14 changes: 14 additions & 0 deletions
14
recipes-devtools/python/python3-powerrelay/labgrid-powerrelay.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
[Unit] | ||
Description=Powerrelay init | ||
After=network-online.target | ||
Wants=network-online.target | ||
|
||
[Service] | ||
Type=simple | ||
Environment="LC_ALL=C.UTF-8" | ||
Environment="LANG=C.UTF-8" | ||
|
||
ExecStart=/usr/bin/powerrelay run /etc/powerrelay/config.yaml | ||
|
||
[Install] | ||
WantedBy=multi-user.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
DESCRIPTION = "REST API to control GPIO chips" | ||
HOMEPAGE = "https://github.com/prevas-dk/labgrid-powerrelay" | ||
LICENSE = "MIT" | ||
LIC_FILES_CHKSUM = "file://LICENSE;md5=20796caa814f193af92c180d146bb7ec" | ||
|
||
RDEPENDS_${PN} = " \ | ||
python3-click \ | ||
python3-aiohttp \ | ||
python3-trafaret \ | ||
python3-trafaret-config \ | ||
python3-aiohttp-jinja2 \ | ||
python3-yarl \ | ||
python3-multidict \ | ||
" | ||
|
||
SRC_URI = " \ | ||
git://github.com/prevas-dk/labgrid-powerrelay.git;protocol=https;branch=master \ | ||
file://labgrid-powerrelay.service \ | ||
" | ||
SRCREV = "bf5d2e11e0f594757d3d97a6a9f38480713aaace" | ||
|
||
S = "${WORKDIR}/git" | ||
|
||
DEPENDS += "${PYTHON_PN}-pytest-runner-native" | ||
|
||
inherit setuptools3 systemd | ||
|
||
SYSTEMD_SERVICE_${PN} = "labgrid-powerrelay.service" | ||
|
||
do_install_append() { | ||
rm -rf "${D}${datadir}" | ||
install -d ${D}${systemd_system_unitdir} | ||
install -m 0644 ${WORKDIR}/labgrid-powerrelay.service ${D}${systemd_system_unitdir}/ | ||
} | ||
|
||
FILES_${PN} += "${systemd_system_unitdir}" |