diff --git a/docker-compose.yml b/docker-compose.yml index 973aeb98..c9c99b7b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -170,7 +170,6 @@ services: amarillo: container_name: amarillo - image: openmove_amarillo:latest build: context: ./ dockerfile: infrastructure/docker/amarillo/Dockerfile diff --git a/infrastructure/docker/amarillo/Dockerfile b/infrastructure/docker/amarillo/Dockerfile index a386a2d7..f80cc966 100644 --- a/infrastructure/docker/amarillo/Dockerfile +++ b/infrastructure/docker/amarillo/Dockerfile @@ -10,3 +10,9 @@ RUN rm /app/conf/region/* && \ # Overwrite config COPY ./amarillo /app + + +COPY ./infrastructure/docker/amarillo/docker-entrypoint.sh ./docker-entrypoint.sh +RUN chmod +x ./docker-entrypoint.sh + +ENTRYPOINT ["./docker-entrypoint.sh"] \ No newline at end of file diff --git a/infrastructure/docker/amarillo/docker-entrypoint.sh b/infrastructure/docker/amarillo/docker-entrypoint.sh new file mode 100644 index 00000000..09a7bf2f --- /dev/null +++ b/infrastructure/docker/amarillo/docker-entrypoint.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash + +# amarillo needs started graphopper, so wait some time to let it startup +echo "sleeping to wait for graphhopper startup..." +sleep 60; +echo "sleeping over. graphhopper are you there?" +bash /app/prestart.sh +uvicorn amarillo.main:app --host 0.0.0.0 --port 80; \ No newline at end of file