Commit afdbc92a authored by Jerome Touvier's avatar Jerome Touvier
Browse files

docker update

parent e6c7bc2c
# Installation de l'application Flask
# Building heavy python dependencies as a first stage
# will build ospy for instance
FROM python:3.9-slim AS python-deps
RUN apt-get update && apt-get install -y --no-install-recommends gcc libc6-dev
COPY requirements.txt /
RUN pip install --no-cache-dir -r /requirements.txt
RUN pip install --no-cache-dir gunicorn
FROM python:3.9-slim
# Get the dependencies from previous stage
COPY --from=python-deps /usr/local/lib/python3.9/site-packages /usr/local/lib/python3.9/site-packages
RUN pip install --no-cache-dir gunicorn
WORKDIR /appli
COPY start*.py ./
COPY apps ./apps/
COPY templates ./templates/
COPY static ./static/
USER 1000
ENTRYPOINT ["gunicorn"]
ENTRYPOINT ["gunicorn", "--bind", ""]
CMD ["start_timeseries:app"]
......@@ -154,8 +154,8 @@ def get_file(params, st):
(file_type, file_ext) = get_file_type(params)
(start, end) = get_bounds(st)
start = UTCDateTime(start).strftime("%Y-%m-%dT%H:%M:%S.%f")[:-3] + "Z"
end = UTCDateTime(end).strftime("%Y-%m-%dT%H:%M:%S.%f")[:-3] + "Z"
start = UTCDateTime(start).strftime("%Y%m%dT%H%M%S") + "Z"
end = UTCDateTime(end).strftime("%Y%m%dT%H%M%S") + "Z"
period = ".".join([start, end])
fname = "resifws-timeseries"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment