mirror of
https://github.com/eduardogsilva/wireguard_webadmin.git
synced 2025-08-26 13:21:14 +00:00
Changed docker-compose to use the images from dockerhub.
This commit is contained in:
36
build_and_push.sh
Executable file
36
build_and_push.sh
Executable file
@@ -0,0 +1,36 @@
|
||||
#!/bin/bash
|
||||
|
||||
IMAGES=(
|
||||
"eduardosilva/wireguard_webadmin:latest"
|
||||
"eduardosilva/wireguard_webadmin_cron:latest"
|
||||
"eduardosilva/wireguard_webadmin_nginx:latest"
|
||||
)
|
||||
|
||||
build_images() {
|
||||
echo "Starting the build of the images..."
|
||||
docker-compose -f docker-compose-build.yml build
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "Build completed successfully."
|
||||
else
|
||||
echo "Error during the image build."
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
push_images() {
|
||||
for IMAGE in "${IMAGES[@]}"; do
|
||||
echo "Pushing image: $IMAGE..."
|
||||
docker push "$IMAGE"
|
||||
if [ $? -eq 0 ]; then
|
||||
echo "$IMAGE pushed successfully."
|
||||
else
|
||||
echo "Error pushing the image: $IMAGE"
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
build_images
|
||||
push_images
|
||||
|
||||
echo "Build and push operations completed successfully."
|
Reference in New Issue
Block a user