dbgate/docker/entrypoint.sh
2022-06-12 19:45:27 +02:00

12 lines
222 B
Bash

#!/bin/sh
HOST_DOMAIN="dockerhost"
ping -q -c1 $HOST_DOMAIN > /dev/null 2>&1
if [ $? != 0 ]
then
HOST_IP=$(ip route | awk 'NR==1 {print $3}')
echo "$HOST_IP $HOST_DOMAIN" >> /etc/hosts
fi
node bundle.js --listen-api