Comment out network creation and inspection in docker-network.sh

This commit is contained in:
2025-07-12 07:53:58 -05:00
parent 07471259b8
commit f9f3997f7e

View File

@@ -21,7 +21,7 @@ fi
DOCKER_DAEMON_FILE="/etc/docker/daemon.json"
ADDRESS_POOL_BASE="10.${octet}.0.0/16"
ADDRESS_POOL_SIZE=24
NETWORK_NAME="bridge_default"
# NETWORK_NAME="bridge_default"
NETWORK_SUBNET="10.${octet}.1.0/24"
# -------------------------------
@@ -49,16 +49,17 @@ echo "Docker config updated at $DOCKER_DAEMON_FILE"
# Delete and recreate network
# -------------------------------
if docker network inspect "$NETWORK_NAME" >/dev/null 2>&1; then
echo "Network '$NETWORK_NAME' exists. Deleting it..."
docker network rm "$NETWORK_NAME"
fi
# if docker network inspect "$NETWORK_NAME" >/dev/null 2>&1; then
# echo "Network '$NETWORK_NAME' exists. Deleting it..."
# docker network rm "$NETWORK_NAME"
# fi
echo "Creating network '$NETWORK_NAME' with subnet $NETWORK_SUBNET..."
docker network create \
--driver=bridge \
--subnet="$NETWORK_SUBNET" \
"$NETWORK_NAME"
# echo "Creating network '$NETWORK_NAME' with subnet $NETWORK_SUBNET..."
# docker network create \
# --driver=bridge \
# --subnet="$NETWORK_SUBNET" \
# "$NETWORK_NAME"
# echo "✅ Done. You may need to restart Docker to apply default address pool changes:"
echo "✅ Done. You may need to restart Docker to apply default address pool changes:"
echo " sudo systemctl restart docker"