fix network creation: use -f for rm, show errors on create
This commit is contained in:
parent
14e60151fd
commit
0d7defff4e
1 changed files with 3 additions and 3 deletions
|
|
@ -210,7 +210,7 @@ if [ "$MODE" = "destroy" ]; then
|
|||
# Stop rootless containers
|
||||
podman stop caddy authelia launcher 2>/dev/null || true
|
||||
podman rm caddy authelia launcher 2>/dev/null || true
|
||||
podman network rm "$NETWORK_NAME" 2>/dev/null || true
|
||||
podman network rm -f "$NETWORK_NAME" 2>/dev/null || true
|
||||
# Wipe target
|
||||
maybe_sudo rm -rf "$TARGET_DIR"
|
||||
maybe_sudo mkdir -p "$TARGET_DIR/config/caddy" "$TARGET_DIR/config/authelia" \
|
||||
|
|
@ -304,8 +304,8 @@ maybe_sudo chown -R "$RUN_USER:" "$BACKUP_DIR" 2>/dev/null || true
|
|||
# ============================================================
|
||||
echo "[*] Deploying containers on $NETWORK_NAME..."
|
||||
|
||||
podman network rm "$NETWORK_NAME" 2>/dev/null || true
|
||||
podman network create --subnet 172.18.0.0/24 "$NETWORK_NAME" 2>/dev/null || true
|
||||
podman network rm -f "$NETWORK_NAME" 2>/dev/null || true
|
||||
podman network create --subnet 172.18.0.0/24 "$NETWORK_NAME"
|
||||
|
||||
# AUTHELIA_SECRET is SESSION_SECRET (Authelia session.secret)
|
||||
AUTHELIA_SECRET="${SESSION_SECRET:-}"
|
||||
|
|
|
|||
Loading…
Reference in a new issue