1 # This file is part of GNU Stow.
3 # GNU Stow is free software: you can redistribute it and/or modify it
4 # under the terms of the GNU General Public License as published by
5 # the Free Software Foundation, either version 3 of the License, or
6 # (at your option) any later version.
8 # GNU Stow is distributed in the hope that it will be useful, but
9 # WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # General Public License for more details.
13 # You should have received a copy of the GNU General Public License
14 # along with this program. If not, see https://www.gnu.org/licenses/.
16 # Build docker image: `docker build -t stowtest`
17 # Run tests: (from stow src directory)
18 # `docker run --rm -it -v $(pwd):$(pwd) -w $(pwd) stowtest`
20 RUN DEBIAN_FRONTEND=noninteractive apt-get update -qq
21 RUN DEBIAN_FRONTEND=noninteractive \
22 apt-get install -y --force-yes -q \
36 && rm -rf /var/lib/apt/lists/*
40 PERLBREW_ROOT=/usr/local/perlbrew \
41 PERLBREW_HOME=/root/.perlbrew \
42 PERLBREW_PATH=/usr/local/perlbrew/bin
43 RUN mkdir -p /usr/local/perlbrew /root \
45 && perlbrew install-cpanm \
46 && perlbrew install-patchperl
47 RUN perlbrew install-multiple -j 4 --notest \
55 # Bootstrap the perl environments
56 COPY ./bootstrap-perls.sh /bootstrap-perls.sh
57 RUN /bootstrap-perls.sh && rm /bootstrap-perls.sh
59 # Add test script to container filesystem
60 COPY ./run-stow-tests.sh /run-stow-tests.sh
62 ENTRYPOINT ["/run-stow-tests.sh"]