Skip to content
Snippets Groups Projects

include TRANSLATIONS_DIR as environment variable in the Docker image

Merged Karel van Klink requested to merge feature/update-dockerfile into develop
All threads resolved!
1 file
+ 2
0
Compare changes
  • Side-by-side
  • Inline
+ 2
0
@@ -2,7+2,7 @@
ARG ARTIFACT_VERSION
RUN pip install \
--pre \
--extra-index-url https://artifactory.software.geant.org/artifactory/api/pypi/geant-swd-pypi/simple \
geant-service-orchestrator==${ARTIFACT_VERSION}
@@ -18,7+18,7 @@
# The app reads the configuration from this location.
# No need to set environment variables in your docker-compose.
ENV OSS_PARAMS_FILENAME=/etc/gso/config.json
# Set the environment variable for the translations directory
ENV TRANSLATIONS_DIR=$(python3 -c "from os import path; import gso; print(path.join(path.split(gso.__file__)[0], 'translations'))" | tail -n 1)
# Start the FastAPI application
CMD ["uvicorn", "gso.main:app", "--host", "0.0.0.0", "--port", "8080"]
Loading