Browse Source

bits for distributed.net on amd64 and arm. swap in your own config unless you want me to get all your credit

sungo 2 months ago
parent
commit
b7c5ffc2e2
4 changed files with 56 additions and 0 deletions
  1. 15 0
      dnet/amd64/Dockerfile
  2. 11 0
      dnet/amd64/dnetc.ini
  3. 19 0
      dnet/arm/Dockerfile
  4. 11 0
      dnet/arm/dnetc.ini

+ 15 - 0
dnet/amd64/Dockerfile

@@ -0,0 +1,15 @@
+FROM alpine:latest AS build
+RUN apk update && apk upgrade
+RUN apk add --no-cache bash curl
+RUN curl -o /tmp/dnetc-current.tar.gz http://http.distributed.net/pub/dcti/current-client/dnetc-linux-x86-elf-uclibc.tar.gz
+RUN mkdir -p /opt
+RUN cd /tmp && tar -xzvf dnetc-current.tar.gz  && mv dnetc*-linux-x86-elf-uclibc /opt/dnetc
+
+FROM scratch
+COPY --from=build /opt/dnetc/dnetc /usr/local/bin/dnetc
+COPY dnetc.ini /usr/local/etc/dnetc.ini
+
+ARG UID=1000
+USER $UID
+ENTRYPOINT [ "/usr/local/bin/dnetc" ]
+CMD [ "-ini", "/usr/local/etc/dnetc.ini", "-priority", "0" ]

+ 11 - 0
dnet/amd64/dnetc.ini

@@ -0,0 +1,11 @@
+[parameters]
+id=sungo@sungo.us
+
+[buffers]
+buffer-only-in-memory=yes
+
+[triggers]
+pause-on-no-mains-power=no
+
+[display]
+progress-indicator=auto-sense

+ 19 - 0
dnet/arm/Dockerfile

@@ -0,0 +1,19 @@
+FROM debian:buster
+
+ENV DEBIAN_FRONTEND=noninteractive
+RUN apt-get update && apt-get upgrade -y && apt-get install -y curl
+
+RUN curl -o /tmp/dnetc-current.tar.gz http://http.distributed.net/pub/dcti/current-client/dnetc-linux-arm-eabi.tar.gz 
+RUN cd /tmp && tar -xzvf dnetc-current.tar.gz && mv dnetc*-linux-arm-eabi /tmp/dnetc
+
+RUN mv /tmp/dnetc/dnetc /usr/local/bin/dnetc
+RUN rm -r /tmp/dnetc
+
+RUN ln -s /lib/ld-linux-armhf.so.3 /lib/ld-linux.so.3
+
+COPY dnetc.ini /usr/local/etc/dnetc.ini
+
+ARG UID=1000
+USER $UID
+ENTRYPOINT [ "/usr/local/bin/dnetc" ]
+CMD [ "-ini", "/usr/local/etc/dnetc.ini", "-priority", "0" ]

+ 11 - 0
dnet/arm/dnetc.ini

@@ -0,0 +1,11 @@
+[parameters]
+id=sungo@sungo.us
+
+[buffers]
+buffer-only-in-memory=yes
+
+[triggers]
+pause-on-no-mains-power=no
+
+[display]
+progress-indicator=auto-sense