|
| 1 | +FROM debian:stable-slim |
| 2 | + |
| 3 | +LABEL maintainer.0="João Fonseca (@joaopaulofonseca)" \ |
| 4 | + maintainer.1="Pedro Branco (@pedrobranco)" \ |
| 5 | + maintainer.2="Rui Marinho (@ruimarinho)" |
| 6 | + |
| 7 | +RUN useradd -r dash \ |
| 8 | + && apt-get update -y \ |
| 9 | + && apt-get install -y curl gnupg unzip \ |
| 10 | + && apt-get clean \ |
| 11 | + && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* \ |
| 12 | + && set -ex \ |
| 13 | + && for key in \ |
| 14 | + B42F6819007F00F88E364FD4036A9C25BF357DD4 \ |
| 15 | + 29590362EC878A81FD3C202B52527BEDABE87984 \ |
| 16 | + ; do \ |
| 17 | + gpg --keyserver keyserver.ubuntu.com --recv-keys "$key" || \ |
| 18 | + gpg --keyserver pgp.mit.edu --recv-keys "$key" || \ |
| 19 | + gpg --keyserver keyserver.pgp.com --recv-keys "$key" || \ |
| 20 | + gpg --keyserver keys.openpgp.org --recv-keys "$key" ; \ |
| 21 | + done |
| 22 | + |
| 23 | +ENV GOSU_VERSION=1.10 |
| 24 | + |
| 25 | +RUN curl -o /usr/local/bin/gosu -fSL https://github.com/tianon/gosu/releases/download/${GOSU_VERSION}/gosu-$(dpkg --print-architecture) \ |
| 26 | + && curl -o /usr/local/bin/gosu.asc -fSL https://github.com/tianon/gosu/releases/download/${GOSU_VERSION}/gosu-$(dpkg --print-architecture).asc \ |
| 27 | + && gpg --verify /usr/local/bin/gosu.asc \ |
| 28 | + && rm /usr/local/bin/gosu.asc \ |
| 29 | + && chmod +x /usr/local/bin/gosu |
| 30 | + |
| 31 | +ARG TARGETPLATFORM |
| 32 | +ENV DASH_VERSION=22.0.0 |
| 33 | +ENV DASH_FOLDER_VERSION=22.0.0 |
| 34 | +ENV DASH_DATA=/home/dash/.dashcore \ |
| 35 | + PATH=/opt/dashcore-${DASH_FOLDER_VERSION}/bin:$PATH |
| 36 | +RUN set -ex \ |
| 37 | + && if [ "${TARGETPLATFORM}" = "linux/amd64" ]; then export TARGETPLATFORM=x86_64-linux-gnu; fi \ |
| 38 | + && if [ "${TARGETPLATFORM}" = "linux/arm64" ]; then export TARGETPLATFORM=aarch64-linux-gnu; fi \ |
| 39 | + && curl -SLO https://github.com/dashpay/dash/releases/download/v${DASH_VERSION}/SHA256SUMS.asc \ |
| 40 | + && curl -SLO https://github.com/dashpay/dash/releases/download/v${DASH_VERSION}/dashcore-${DASH_VERSION}-${TARGETPLATFORM}.tar.gz \ |
| 41 | + && curl -SLO https://github.com/dashpay/dash/releases/download/v${DASH_VERSION}/dashcore-${DASH_VERSION}-${TARGETPLATFORM}.tar.gz.asc \ |
| 42 | + && gpg --verify dashcore-${DASH_VERSION}-${TARGETPLATFORM}.tar.gz.asc \ |
| 43 | + && tar -xzf dashcore-${DASH_VERSION}-${TARGETPLATFORM}.tar.gz -C /opt \ |
| 44 | + && rm *.tar.gz |
| 45 | + |
| 46 | +VOLUME ["/home/dash/.dashcore"] |
| 47 | + |
| 48 | +COPY docker-entrypoint.sh /entrypoint.sh |
| 49 | + |
| 50 | +ENTRYPOINT ["/entrypoint.sh"] |
| 51 | + |
| 52 | +EXPOSE 9998 9999 19898 19998 19999 |
| 53 | + |
| 54 | +CMD ["dashd"] |
0 commit comments