Add scripts and port mapping env vars
This commit is contained in:
26
run-test.sh
Executable file
26
run-test.sh
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
# Run test and cleanup afterwards
|
||||
set -e
|
||||
|
||||
COMPOSE_FILE="docker-compose-frontend.yml"
|
||||
|
||||
echo "🚀 Running HarborForge Test..."
|
||||
|
||||
# Clean any previous containers first
|
||||
docker compose -f "$COMPOSE_FILE" down 2>/dev/null || true
|
||||
|
||||
# Run test
|
||||
docker compose -f "$COMPOSE_FILE" run --rm test
|
||||
TEST_EXIT_CODE=$?
|
||||
|
||||
echo ""
|
||||
echo "🧹 Cleaning up containers and volumes..."
|
||||
docker compose -f "$COMPOSE_FILE" down -v
|
||||
|
||||
if [ $TEST_EXIT_CODE -eq 0 ]; then
|
||||
echo "✅ Test passed!"
|
||||
else
|
||||
echo "❌ Test failed with exit code: $TEST_EXIT_CODE"
|
||||
fi
|
||||
|
||||
exit $TEST_EXIT_CODE
|
||||
Reference in New Issue
Block a user