-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
50 lines (45 loc) · 2 KB
/
Dockerfile
File metadata and controls
50 lines (45 loc) · 2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
FROM therealspring/python-gdal:3.1.2
ARG CURRENT_HASH=hashisundefined
ENV ENV_CURRENT_HASH=$CURRENT_HASH
RUN apt-get update -qq && \
apt-get install -y \
curl \
git \
git-lfs \
libspatialindex-dev \
openssl \
python3-pip \
gcc \
python3-dev \
python3-setuptools \
python3-tk
SHELL ["/bin/bash", "-c"]
#WORKDIR /usr/local/gcloud-sdk
#RUN wget https://dl.google.com/dl/cloudsdk/channels/rapid/downloads/google-cloud-sdk-284.0.0-linux-x86_64.tar.gz && tar -xvzf google-cloud-sdk-284.0.0-linux-x86_64.tar.gz
#RUN ./google-cloud-sdk/install.sh
#RUN source /usr/local/gcloud-sdk/google-cloud-sdk/completion.bash.inc
#RUN source /usr/local/gcloud-sdk/google-cloud-sdk/path.bash.inc
#RUN echo "export PATH=$PATH:/usr/local/gcloud-sdk/google-cloud-sdk/bin" >> /root/.bashrc
#COPY /ecoshard-bucket-reader-key.json /usr/local//ecoshard-bucket-reader-key.json
#RUN /usr/local/gcloud-sdk/google-cloud-sdk/bin/gcloud auth activate-service-account --key-file=/usr/local//ecoshard-bucket-reader-key.json
#RUN rm /usr/local//ecoshard-bucket-reader-key.json
# CRC mod for good gsutil -m cp mode
#RUN pip uninstall crcmod -y && pip install --no-cache-dir -U crcmod
RUN git clone https://github.com/therealspring/inspring.git /usr/local/inspring
WORKDIR /usr/local/inspring
RUN pip3 install -r requirements.txt
RUN /usr/bin/python setup.py install
# Use the same requirements as inspring for invest
WORKDIR /usr/local/
RUN git clone https://github.com/natcap/invest.git
WORKDIR /usr/local/invest/
RUN git checkout 3.9.0
RUN cp /usr/local/inspring/requirements.txt .
RUN /usr/bin/python setup.py install
RUN pip3 install torch==1.8.1+cpu torchvision==0.9.1+cpu torchaudio==0.8.1 -f https://download.pytorch.org/whl/torch_stable.html
RUN pip3 uninstall ecoshard -y && pip3 install git+https://github.com/therealspring/ecoshard.git@b9b4580e0cf2992c164aeb61950d84c64def57ef
RUN pip3 install geopandas
RUN pip3 install ray[tune]
RUN pip3 install editdistance
WORKDIR /usr/local/workspace
ENTRYPOINT ["/usr/bin/python"]