-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Trygve Aspenes
committed
Dec 15, 2023
1 parent
add2133
commit 96eac48
Showing
1 changed file
with
0 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,20 +2,11 @@ FROM docker.io/mambaorg/micromamba:1.5.1-jammy | |
|
||
LABEL maintainer="[email protected]" | ||
|
||
#ENV DEBIAN_FRONTEND=noninteractive | ||
|
||
#RUN apt-get update && apt-get -y dist-upgrade && apt-get install -y apt-utils build-essential git | ||
# python3-dev python3-venv python3-mapscript | ||
#cmake libpng-dev libcurl4-gnutls-dev libjpeg8-dev libaprutil1-dev libapr1-dev libpixman-1-dev libgdal-dev libpq-dev libsqlite3-dev libtiff-dev libgeotiff-dev libgeos-dev swig libfreetype-dev | ||
#ENV VIRTUAL_ENV=/opt/venv | ||
#ENV PATH="$VIRTUAL_ENV/bin:$PATH" | ||
ENV MAPGEN_REPO=https://github.com/metno/mapgen-fastapi.git \ | ||
MAPGEN_VERSION=main | ||
|
||
COPY ./app /app | ||
# Install dependencies: | ||
#COPY requirements.txt . | ||
#COPY environment.yaml . | ||
COPY --chown=$MAMBA_USER:$MAMBA_USER environment.yaml /tmp/environment.yaml | ||
RUN micromamba install -y -n base --file /tmp/environment.yaml | ||
|
||
|
@@ -25,18 +16,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ | |
&& rm -rf /var/lib/apt/lists/* | ||
USER $MAMBA_USER | ||
RUN /opt/conda/bin/pip install "git+${MAPGEN_REPO}@${MAPGEN_VERSION}" | ||
# RUN python3 -m venv $VIRTUAL_ENV \ | ||
# && pip install -U pip \ | ||
# && pip install -r requirements.txt \ | ||
# && pip install "git+${MAPGEN_REPO}@${MAPGEN_VERSION}" | ||
# && ln -s /opt/venv/lib/python3.10/site-packages/mapgen/favicon.ico /app | ||
# && git clone https://github.com/MapServer/mapserver.git /tmp/mapserver \ | ||
# && cd /tmp/mapserver \ | ||
# && git checkout tags/rel-8-0-0 \ | ||
# && mkdir -p /tmp/mapserver/build && cd /tmp/mapserver/build \ | ||
# && cmake .. -DWITH_POSTGRESQL=1 -DWITH_TIFF=1 -DWITH_GEOTIFF=1 -DWITH_MEMCACHE=1 -DWITH_CURL=1 -DWITH_PYTHON=1 -DWITH_PROTOBUFC=0 -DWITH_FRIBIDI=0 -DWITH_HARFBUZZ=0 -DWITH_CAIRO=0 -DWITH_FCGI=0 -DWITH_PYMAPSCRIPT_ANNOTATIONS=1 \ | ||
# && make install \ | ||
# && make clean | ||
|
||
COPY --chown=$MAMBA_USER:$MAMBA_USER ./start.sh /start.sh | ||
|
||
|
@@ -46,13 +25,8 @@ COPY --chown=$MAMBA_USER:$MAMBA_USER ./start-reload.sh /start-reload.sh | |
RUN chmod +x /start.sh \ | ||
&& chmod +x /start-reload.sh | ||
|
||
#RUN git clone --branch upload-map-files-to-ceph https://github.com/metno/mapgen-fastapi.git | ||
# ENV NCPLOTDIR /opt/ncplot/ | ||
|
||
WORKDIR /app | ||
|
||
# ENV PYTHONPATH=/app:/lib/python3/dist-packages/ | ||
|
||
EXPOSE 80 | ||
|
||
# Run the start script, it will check for an /app/prestart.sh script (e.g. for migrations) | ||
|