Files
Goedge/docker/build/run_user.sh

21 lines
423 B
Bash
Raw Normal View History

2024-07-30 14:30:12 +08:00
#!/usr/bin/env sh
. /build/set_hosts.sh
function pre_config() {
if [ ! -e ${ROOT_DIR}/edge-user/configs/api_user.yaml ]; then
touch ${ROOT_DIR}/edge-user/configs/api_user.yaml
cat >> ${ROOT_DIR}/edge-user/configs/api_user.yaml << EOF
rpc.endpoints: [ "${ENDPOINTS}" ]
nodeId: "${NODEID}"
secret: "${SECRET}"
EOF
fi
}
ROOT_DIR='/usr/local/goedge'
set_hosts
pre_config
${ROOT_DIR}/edge-user/bin/edge-user