Skip to content

Commit

Permalink
clean-local.sh to remove local builds and venvs (#16597)
Browse files Browse the repository at this point in the history
  • Loading branch information
evantahler authored Sep 12, 2022
1 parent 3039ebf commit 6249b48
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tools/bin/clean_images.sh → tools/bin/clean_local.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,19 @@ set -e
echo "Disk space before:"
docker run --rm busybox df -h

# Clean docker images
docker images "airbyte/source*" | grep airbyte | grep -v postgres | tr -s ' ' | cut -d" " -f 3 | xargs -n 1 -I {} docker image rm {}
docker images "airbyte/destination*" | grep airbyte | grep -v postgres | tr -s ' ' | cut -d" " -f 3 | xargs -n 1 -I {} docker image rm {}
docker image prune --force

# Clean build artifacts
cd $SCRIPT_DIRECTORY && cd ../..
rm -rf build/*
rm -rf */*/build
rm -rf airbyte-integrations/*/build
rm -rf airbyte-integrations/*/*/build
rm -rf airbyte-integrations/connectors/*/.venv
cd $SCRIPT_DIRECTORY

echo "Disk space after:"
docker run --rm busybox df -h

0 comments on commit 6249b48

Please sign in to comment.