stock-bot/apps/wcag-ada/scripts/build-images.sh
2025-06-28 11:11:34 -04:00

41 lines
No EOL
986 B
Bash
Executable file

#!/bin/bash
set -e
# Script to build all Docker images locally
echo "Building WCAG-ADA Docker images..."
# Get the repository root (two levels up from scripts directory)
REPO_ROOT=$(cd "$(dirname "$0")/../../.." && pwd)
WCAG_ROOT=$(cd "$(dirname "$0")/.." && pwd)
# Set default registry if not provided
REGISTRY=${DOCKER_REGISTRY:-"wcag-ada"}
# Build API image
echo "Building API image..."
docker build \
-f "$WCAG_ROOT/api/Dockerfile" \
-t "$REGISTRY/api:latest" \
"$REPO_ROOT"
# Build Worker image
echo "Building Worker image..."
docker build \
-f "$WCAG_ROOT/worker/Dockerfile" \
-t "$REGISTRY/worker:latest" \
"$REPO_ROOT"
# Build Dashboard image
echo "Building Dashboard image..."
docker build \
-f "$WCAG_ROOT/dashboard/Dockerfile" \
-t "$REGISTRY/dashboard:latest" \
"$REPO_ROOT"
echo "All images built successfully!"
echo ""
echo "Images created:"
echo " - $REGISTRY/api:latest"
echo " - $REGISTRY/worker:latest"
echo " - $REGISTRY/dashboard:latest"