Skip to content
Snippets Groups Projects
Commit 5898124a authored by Vladimir Petrigo's avatar Vladimir Petrigo
Browse files

Add libcap dependency for Node-RED Noble addon

Due to the fact that we use node-red user for Node-RED instance it is
not possible for noble package to use BLE hardware without root
privileges. So we have to provide a cap_net_raw capability to Node.js to
allow such packages to use system hardware
parent 7c256002
No related branches found
No related tags found
No related merge requests found
......@@ -23,6 +23,9 @@ if [[ ! -e ${LOG_DIR} ]]; then
fi
chown -R $USER:$USER_GROUP ${LOG_DIR}
# grant node binary cap_net_raw privileges, so it can
# start/stop BLE advertising
setcap cap_net_raw+eip $(eval readlink -f `which node`)
case "$1" in
start)
......
......@@ -3,7 +3,7 @@ LICENSE = "Apache-2.0"
LIC_FILES_CHKSUM = "file://LICENSE;md5=2ee41112a44fe7014dce33e26468ba93"
DEPENDS = "nodejs-native"
RDEPENDS_${PN} += " bash node-red bluez5"
RDEPENDS_${PN} += " bash node-red bluez5 libcap libcap-bin"
SECTION = "nodered-package"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment