sanity check

pull/1/head
Jordan Sokolic 2020-02-19 23:04:18 +02:00
parent ba90bc54a3
commit 9c21adec00
1 changed files with 2 additions and 1 deletions

3
run.sh
View File

@ -75,6 +75,7 @@ function _set_hairpin() {
}
function _create_or_start_container() {
docker inspect $BUILD_TAG >/dev/null 2>&1 || { echo "no image '$BUILD_TAG' found, did you forget to run 'make build'?"; exit 1; }
docker inspect $CONTAINER >/dev/null 2>&1
if [[ $? -eq 0 ]]; then
echo "* starting container '$CONTAINER'"
@ -89,7 +90,7 @@ function _create_or_start_container() {
--hostname openwrt \
--ip $LAN_ADDR \
--sysctl net.ipv4.conf.default.arp_ignore=1 \
--name $CONTAINER openwrt >/dev/null
--name $CONTAINER $BUILD_TAG >/dev/null
docker network connect $WAN_NAME $CONTAINER
_gen_config