UNCLASSIFIED - NO CUI

Skip to content
Snippets Groups Projects
Verified Commit a35a3a8d authored by Patrick Tafoya's avatar Patrick Tafoya
Browse files

BULL-3225-better-startup - Fix for depends on condition to properly wait for...

BULL-3225-better-startup - Fix for depends on condition to properly wait for startup. Fix for broken db due to user change. Updated setup.sh script for alpine compatability.
parent 2fd86ff9
No related branches found
No related tags found
1 merge request!11BULL-3225-better-startup
......@@ -10,10 +10,4 @@ services:
- .:/local-dev # Map the root folder to /local-dev in the container
command: >
sh -c "chmod +x /local-dev/scripts/setup.sh && /local-dev/scripts/setup.sh"
healthcheck:
test: "sh -c 'test -d /local-dev/reports'"
interval: 10s
timeout: 5s
retries: 3
start_period: 5s
restart: "no"
......@@ -28,7 +28,7 @@ services:
db:
condition: service_healthy
startup:
condition: service_healthy
condition: service_completed_successfully
healthcheck:
# due to the way the api authorizes requests, we expect a 401
test: /opt/healthcheck/healthcheck.sh http://localhost:$$PORT/api/docs 401
......
......@@ -28,7 +28,7 @@ services:
db:
condition: service_healthy
startup:
condition: service_healthy
condition: service_completed_successfully
healthcheck:
test: curl -f http://localhost:$$PORT/api/health
timeout: 10s
......
......@@ -3,7 +3,6 @@ services:
db:
image: postgres:11-alpine
container_name: xx_project_name_xx-db
user: "${UID:-1000}:${GID:-1000}" # Default to 1000:1000 if UID/GID not set
entrypoint: /postgres-entrypoint.sh
command: >
-c ssl=on
......@@ -22,7 +21,7 @@ services:
- "5432:5432"
depends_on:
startup:
condition: service_healthy
condition: service_completed_successfully
healthcheck:
test: >
pg_isready -d $$POSTGRES_DB -U $$POSTGRES_USER
......
......@@ -21,7 +21,7 @@ services:
- xx_project_name_xx-net
depends_on:
startup:
condition: service_healthy
condition: service_completed_successfully
healthcheck:
test: curl -f http://localhost:$$PORT
timeout: 10s
......
......@@ -16,3 +16,6 @@ services:
volumes:
- ./:/local-dev
- ./xx_project_name_xx<<subProject>>:/app
depends_on:
startup:
condition: service_completed_successfully
......@@ -16,3 +16,6 @@ services:
volumes:
- ./:/local-dev
- ./xx_project_name_xx<<subProject>>:/app
depends_on:
startup:
condition: service_completed_successfully
......@@ -13,3 +13,6 @@ services:
volumes:
- ./:/local-dev
- ./xx_project_name_xx<<subProject>>:/app
depends_on:
startup:
condition: service_completed_successfully
......@@ -15,3 +15,6 @@ services:
volumes:
- ./:/local-dev
- ./xx_project_name_xx<<subProject>>:/app
depends_on:
startup:
condition: service_completed_successfully
......@@ -16,3 +16,6 @@ services:
volumes:
- ./:/local-dev
- ./xx_project_name_xx<<subProject>>:/app
depends_on:
startup:
condition: service_completed_successfully
#!/bin/bash
#!/bin/sh
# Add execute permissions to all .sh files in ./scripts/ and its subdirectories
find ./scripts/ -type f -name '*.sh' -exec chmod +x {} \;
# Add execute permissions to all .sh files in ./config/ and its subdirectories
find ./config/ -type f -name '*.sh' -exec chmod +x {} \;
# Ensure the /cat-shoe-local-dev/reports folder exists
mkdir -p ./reports
echo "Setup script completed successfully!"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment