diff --git a/Dockerfile b/Dockerfile index 61330bb..ede5e62 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,9 +9,12 @@ RUN cd /src/goproxy &&\ FROM golang:alpine +ARG ARCH=amd64 + # Add tini ENV TINI_VERSION v0.19.0 -ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini-static-amd64 /usr/bin/tini +ENV TINI_ARCH=$ARCH +ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini-static-${TINI_ARCH} /usr/bin/tini RUN chmod +x /usr/bin/tini RUN apk add --no-cache -U git mercurial subversion diff --git a/README.md b/README.md index 8a99d00..2a6609d 100644 --- a/README.md +++ b/README.md @@ -71,6 +71,20 @@ git config --global url."https://${GITHUB_PERSONAL_ACCESS_TOKEN}@github.com/".in This can be done for other git providers as well, following the same pattern +## Build docker image + +If you want to build the docker image locally (you don't have to): + +```shell +docker build -t goproxy/goproxy:latest . +``` + +or if you are running on arm64 + +```shell +docker build --build-arg ARCH=arm64 -t goproxy/goproxy:latest . +``` + ## Use docker image ```shell