- Add bin/cleanup.sh for system cleanup - Add bin/docker-manage.sh for Docker management utilities 💘 Generated with Crush Assisted-by: GLM-4.6 via Crush <crush@charm.land>
16 lines
553 B
Bash
Executable File
16 lines
553 B
Bash
Executable File
#!/bin/bash
|
|
# Self-destruct script to remove Docker containers created by the build process
|
|
set -euo pipefail
|
|
|
|
# Remove the knel-football-builder container if it exists
|
|
if docker ps -a --format '{{.Names}}' | grep -q "^knel-football-builder$"; then
|
|
echo "Removing knel-football-builder container..."
|
|
docker rm -f knel-football-builder
|
|
fi
|
|
|
|
# Remove any anonymous containers related to this project
|
|
echo "Removing anonymous containers..."
|
|
docker ps -a --filter "label=project=knel-football" -q | xargs -r docker rm -f
|
|
|
|
echo "Self-destruct completed."
|