Dockerfile.aarch64 931 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. FROM arm64v8/alpine:latest
  2. # Install system utils & Gogs runtime dependencies
  3. ADD https://github.com/tianon/gosu/releases/download/1.9/gosu-arm64 /usr/sbin/gosu
  4. RUN chmod +x /usr/sbin/gosu \
  5. && echo http://dl-2.alpinelinux.org/alpine/edge/community/ >> /etc/apk/repositories \
  6. && apk --no-cache --no-progress add \
  7. bash \
  8. ca-certificates \
  9. curl \
  10. git \
  11. linux-pam \
  12. openssh \
  13. s6 \
  14. shadow \
  15. socat \
  16. tzdata \
  17. rsync
  18. ENV GOGS_CUSTOM /data/gogs
  19. # Configure LibC Name Service
  20. COPY docker/nsswitch.conf /etc/nsswitch.conf
  21. COPY docker /app/gogs/docker
  22. COPY templates /app/gogs/templates
  23. COPY public /app/gogs/public
  24. WORKDIR /app/gogs/build
  25. COPY . .
  26. RUN ./docker/build-go.sh \
  27. && ./docker/build.sh \
  28. && ./docker/finalize.sh
  29. # Configure Docker Container
  30. VOLUME ["/data"]
  31. EXPOSE 22 3000
  32. ENTRYPOINT ["/app/gogs/docker/start.sh"]
  33. CMD ["/bin/s6-svscan", "/app/gogs/docker/s6/"]