gecko-dev/taskcluster/docker/decision/Dockerfile
Mike Hommey 5f8431c3b1 Bug 1429669 - Separate mercurial conf from install-mercurial.sh. r=dustin
The install-mercurial.sh script currently installs a global mercurial
configuration after installing mercurial manually. In order to share
that configuration with docker images installing a mercurial package
through packages tasks, we move it to a separate file.

We however keep the part setting web.cacerts in install-mercurial.sh,
since it uses a path depending on what kind of environment the script is
run. Moreover, the instructions that come with mercurial to build
Debian packages come with web.cacerts set to the right path already, so
it's not needed in that case anyways.

At the same time, use multiple files in /etc/mercurial/hgrc.d/ instead
of a single /etc/mercurial/hgrc file.

--HG--
extra : rebase_source : 8140d8243cf012489025afe058f467c72224c891
2018-01-11 14:01:31 +09:00

33 lines
1.1 KiB
Docker

FROM ubuntu:16.04
MAINTAINER Greg Arndt <garndt@mozilla.com>
# Add worker user
RUN mkdir /builds
RUN useradd -d /builds/worker -s /bin/bash -m worker
RUN mkdir /builds/worker/artifacts && chown worker:worker /builds/worker/artifacts
# %include python/mozbuild/mozbuild/action/tooltool.py
ADD topsrcdir/python/mozbuild/mozbuild/action/tooltool.py /tmp/tooltool.py
# %include testing/mozharness/external_tools/robustcheckout.py
ADD topsrcdir/testing/mozharness/external_tools/robustcheckout.py /usr/local/mercurial/robustcheckout.py
# %include taskcluster/docker/recipes/hgrc
COPY topsrcdir/taskcluster/docker/recipes/hgrc /etc/mercurial/hgrc.d/mozilla.rc
# %include taskcluster/docker/recipes/install-mercurial.sh
ADD topsrcdir/taskcluster/docker/recipes/install-mercurial.sh /tmp/install-mercurial.sh
ADD system-setup.sh /tmp/system-setup.sh
RUN bash /tmp/system-setup.sh
# %include taskcluster/docker/recipes/run-task
ADD topsrcdir/taskcluster/docker/recipes/run-task /builds/worker/bin/run-task
ENV PATH /builds/worker/bin:$PATH
ENV SHELL /bin/bash
ENV HOME /builds/worker
# Set a default command useful for debugging
CMD ["/bin/bash", "--login"]