Skip to content

Commit

Permalink
connect to host dbus if mapped
Browse files Browse the repository at this point in the history
  • Loading branch information
hilschernetpi committed Sep 4, 2020
1 parent f8576df commit 9632f52
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \
org.label-schema.vcs-ref=$VCS_REF

#version
ENV HILSCHERNETPI_NODERED_VERSION 1.6.2
ENV HILSCHERNETPI_NODERED_VERSION 1.6.3

#labeling
LABEL maintainer="netpi@hilscher.com" \
Expand Down
12 changes: 8 additions & 4 deletions init.d/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,11 @@ else
ip link delete dummy0 >/dev/null 2>&1
fi

# start dbus as background task
/etc/init.d/dbus start
# check if dbus address is already defined -> then dbus-deamon of host shall be used
if [[ ! -d "/var/run/dbus/system_bus_socket" ]]; then
# else start a dbus daemon instance in the container
/etc/init.d/dbus start
fi

pidbt=0

Expand All @@ -34,8 +37,9 @@ term_handler() {
fi

echo "terminating dbus ..."
/etc/init.d/dbus stop

if [[ ! -d "/var/run/dbus/system_bus_socket" ]]; then
/etc/init.d/dbus stop
fi

exit 143; # 128 + 15 -- SIGTERM
}
Expand Down

0 comments on commit 9632f52

Please sign in to comment.