Debian Codegraph @

Dockerfile

raw
1 # Minimal Dockerfile of a base image with Catmandu core on Debian stretch
2 FROM debian:stretch-slim
3
4 LABEL LibreCat community
5
6 ADD docker/apt.txt .
7 # Perl packages used by Catmandu (if available as Debian package) and cpanm
8 RUN apt-get update && apt-get install -y --no-install-recommends \
9 $(grep -vE "^\s*#" apt.txt | tr "\n" " ") cpanminus \
10 && rm -rf /var/lib/apt/lists/*
11
12 ADD . /tmp/catmandu
13
14 WORKDIR /tmp/catmandu
15
16 # install from source
17 RUN cpanm -n -q --installdeps --skip-satisfied .
18 RUN perl Build.PL && ./Build && ./Build install
19
20 # cleanup sources
21 WORKDIR /
22 RUN rm -rf /tmp/catmandu
23
24 # make user feel home
25 RUN adduser --home /home/catmandu --uid 1000 --disabled-password --gecos "" catmandu
26 WORKDIR /home/catmandu
27 USER catmandu
28
29 # Default command
30 CMD ["bash"]