Dockerfile 1.23 KB
Newer Older
Matthias Rüster's avatar
Matthias Rüster committed
1
2
3
FROM alpine:3.11.6

RUN apk add --update \
Matthias Rüster's avatar
Matthias Rüster committed
4
    curl \
5
    make \
Matthias Rüster's avatar
Matthias Rüster committed
6
7
8
    g++ && \
    mkdir /data

9
10
11
12
COPY *.cpp /root/
COPY *.h /root/
COPY *.txt /root/
COPY Makefile /root/
Matthias Rüster's avatar
Matthias Rüster committed
13
14
15

WORKDIR /root

16
17
18
19
RUN wget "ftp://topex.ucsd.edu/pub/srtm30_plus/topo30/topo30" -O topo30 && \
    A=$(md5sum topo30 | cut -d " " -f 1) && \
    test "$A" = "3f9d746674747bf2c01d8b05b7cccb42" && \
    make && \
Matthias Rüster's avatar
Matthias Rüster committed
20
    ./srtmRead -range 0 360 -90 90 -fmt DSBB && \
Matthias Rüster's avatar
Matthias Rüster committed
21
    mv srtmRead.out.grd /data/grid_30.grd && \
Matthias Rüster's avatar
Matthias Rüster committed
22
    ./srtmRead -range 0 360 -90 90 -resample 2 -fmt DSBB && \
Matthias Rüster's avatar
Matthias Rüster committed
23
    mv srtmRead.out.grd /data/grid_60.grd && \
Matthias Rüster's avatar
Matthias Rüster committed
24
25
26
    ./srtmRead -range 0 360 -90 90 -resample 4 -fmt DSBB && \
    mv srtmRead.out.grd /data/grid_120.grd && \
    ./srtmRead -range 0 360 -90 90 -resample 8 -fmt DSBB && \
27
    mv srtmRead.out.grd /data/grid_240.grd && \
28
29
30
31
32
33
34
35
    ./srtmRead -range 0 360 -90 90 -fmt XYZ && \
    mv srtmRead.out.grd /data/grid_30.xyz && \
    ./srtmRead -range 0 360 -90 90 -resample 2 -fmt XYZ && \
    mv srtmRead.out.grd /data/grid_60.xyz && \
    ./srtmRead -range 0 360 -90 90 -resample 4 -fmt XYZ && \
    mv srtmRead.out.grd /data/grid_120.xyz && \
    ./srtmRead -range 0 360 -90 90 -resample 8 -fmt XYZ && \
    mv srtmRead.out.grd /data/grid_240.xyz && \
36
    rm topo30
Matthias Rüster's avatar
Matthias Rüster committed
37
38

VOLUME [ "/data" ]