Skip to content

Commit

Permalink
Save space by removing images immediately after building
Browse files Browse the repository at this point in the history
Signed-off-by: Addisu Z. Taddese <[email protected]>
  • Loading branch information
azeey committed Sep 20, 2023
1 parent 3d884be commit 5a22e95
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions tools/build_docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,22 +29,26 @@

if [[ $1 == 'all' || $1 == 'citadel' || $1 == 'Citadel' ]]; then
echo -e "\e[46m\e[30mUploading documentation for Citadel\e[0m\e[39m"
docker build -t gz-citadel-docs -f Dockerfile.citadel --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker build -f Dockerfile.citadel --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker image prune -f
fi

if [[ $1 == 'all' || $1 == 'fortress' || $1 == 'Fortress' ]]; then
echo -e "\e[46m\e[30mUploading documentation for Fortress\e[0m\e[39m"
docker build -t gz-fortress-docs -f Dockerfile.fortress --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker build -f Dockerfile.fortress --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker image prune -f
fi

if [[ $1 == 'all' || $1 == 'garden' || $1 == 'Garden' ]]; then
echo -e "\e[46m\e[30mUploading documentation for Garden\e[0m\e[39m"
docker build -t gz-garden-docs -f Dockerfile.garden --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker build -f Dockerfile.garden --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker image prune -f
fi

if [[ $1 == 'all' || $1 == 'harmonic' || $1 == 'Harmonic' ]]; then
echo -e "\e[46m\e[30mUploading documentation for Harmonic\e[0m\e[39m"
docker build -t gz-harmonic-docs -f Dockerfile.harmonic --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker build -f Dockerfile.harmonic --build-arg GZ_VERSION_PASSWORD --build-arg GZ_VERSION_DATE=`date -Iseconds` --no-cache --build-arg AWS_ACCESS_KEY_ID --build-arg AWS_SECRET_ACCESS_KEY .
docker image prune -f
fi


Expand Down

0 comments on commit 5a22e95

Please sign in to comment.