More Docker. Easy Access. New Streamlined Plans. Learn more.

circleci/elixir

Verified Publisher

By CircleCI

Updated about 3 years ago

CircleCI images for Elixir

Image
4

5M+

Dockerfile
### ### this Dockerfile is an example representing one variant of this image; ### please see https://github.com/circleci-public/circleci-dockerfiles ### for a complete list of Dockerfiles for each tag/variant of this image ### FROM elixir:1.11.4 # make Apt non-interactive RUN echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/90circleci \ && echo 'DPkg::Options "--force-confnew";' >> /etc/apt/apt.conf.d/90circleci ENV DEBIAN_FRONTEND=noninteractive # Debian Jessie is EOL'd and original repos don't work. # Switch to the archive mirror until we can get people to # switch to Stretch. RUN if grep -q Debian /etc/os-release && grep -q jessie /etc/os-release; then \ rm /etc/apt/sources.list \ && echo "deb http://archive.debian.org/debian/ jessie main" >> /etc/apt/sources.list \ && echo "deb http://security.debian.org/debian-security jessie/updates main" >> /etc/apt/sources.list \ ; fi # Make sure PATH includes ~/.local/bin # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=839155 # This only works for root. The circleci user is done near the end of this Dockerfile RUN echo 'PATH="$HOME/.local/bin:$PATH"' >> /etc/profile.d/user-local-path.sh # man directory is missing in some base images # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=863199 RUN apt-get update \ && mkdir -p /usr/share/man/man1 \ && apt-get install -y \ git mercurial xvfb apt \ locales sudo openssh-client ca-certificates tar gzip parallel \ net-tools netcat unzip zip bzip2 gnupg curl wget make # Set timezone to UTC by default RUN ln -sf /usr/share/zoneinfo/Etc/UTC /etc/localtime # Use unicode RUN locale-gen C.UTF-8 || true ENV LANG=C.UTF-8 # install jq RUN JQ_URL="https://circle-downloads.s3.amazonaws.com/circleci-images/cache/linux-amd64/jq-latest" \ && curl --silent --show-error --location --fail --retry 3 --output /usr/bin/jq $JQ_URL \ && chmod +x /usr/bin/jq \ && jq --version # Install Docker #> # To install, run the following commands as root: #> curl -fsSLO https://download.docker.com/linux/static/stable/x86_64/docker-17.05.0-ce.tgz && tar --strip-components=1 -xvzf docker-17.05.0-ce.tgz -C /usr/local/bin #> #> # Then start docker in daemon mode: #> /usr/local/bin/dockerd RUN set -ex \ && export DOCKER_VERSION=docker-19.03.12.tgz \ && DOCKER_URL="https://download.docker.com/linux/static/stable/x86_64/${DOCKER_VERSION}" \ && echo Docker URL: $DOCKER_URL \ && curl --silent --show-error --location --fail --retry 3 --output /tmp/docker.tgz "${DOCKER_URL}" \ && ls -lha /tmp/docker.tgz \ && tar -xz -C /tmp -f /tmp/docker.tgz \ && mv /tmp/docker/* /usr/bin \ && rm -rf /tmp/docker /tmp/docker.tgz \ && which docker \ && (docker version || true) # docker compose RUN COMPOSE_URL="https://circle-downloads.s3.amazonaws.com/circleci-images/cache/linux-amd64/docker-compose-latest" \ && curl --silent --show-error --location --fail --retry 3 --output /usr/bin/docker-compose $COMPOSE_URL \ && chmod +x /usr/bin/docker-compose \ && docker-compose version # install dockerize RUN DOCKERIZE_URL="https://circle-downloads.s3.amazonaws.com/circleci-images/cache/linux-amd64/dockerize-latest.tar.gz" \ && curl --silent --show-error --location --fail --retry 3 --output /tmp/dockerize-linux-amd64.tar.gz $DOCKERIZE_URL \ && tar -C /usr/local/bin -xzvf /tmp/dockerize-linux-amd64.tar.gz \ && rm -rf /tmp/dockerize-linux-amd64.tar.gz \ && dockerize --version RUN groupadd --gid 3434 circleci \ && useradd --uid 3434 --gid circleci --shell /bin/bash --create-home circleci \ && echo 'circleci ALL=NOPASSWD: ALL' >> /etc/sudoers.d/50-circleci \ && echo 'Defaults env_keep += "DEBIAN_FRONTEND"' >> /etc/sudoers.d/env_keep # BEGIN IMAGE CUSTOMIZATIONS # END IMAGE CUSTOMIZATIONS USER circleci ENV PATH /home/circleci/.local/bin:/home/circleci/bin:${PATH} CMD ["/bin/sh"]