blob: 4059b1822a3481a0d49f7002929de27f4fe9ea30 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
#!/bin/sh
set -e
# Reenable the services only if systemctl is available
if command -v systemctl >/dev/null; then
### Enable the sm services if the device is connected to c8y cloud
if [ -f "/etc/tedge/mosquitto-conf/c8y-bridge.conf" ]; then
# start and enable tedge-agent
systemctl start tedge-agent.service
systemctl enable tedge-agent.service
fi
fi
# Initialize the agent
runuser -u tedge -- tedge_agent --init
#DEBHELPER#
|