FROM alpine:3.2
-MAINTAINER roemer.jp@gmail.com
+MAINTAINER jp@roemer.im
# Install system utils & Gogs runtime dependencies
ADD https://github.com/tianon/gosu/releases/download/1.6/gosu-amd64 /usr/sbin/gosu
WORKDIR /app/gogs/
RUN ./docker/build.sh
+# Configure LibC Name Service
+COPY docker/nsswitch.conf /etc/nsswitch.conf
+
# Configure Docker Container
VOLUME ["/data"]
EXPOSE 22 3000
FROM sander85/rpi-alpine:latest
-MAINTAINER roemer.jp@gmail.com, raxetul@gmail.com
+MAINTAINER jp@roemer.im, raxetul@gmail.com
# Install system utils & Gogs runtime dependencies
ADD https://github.com/tianon/gosu/releases/download/1.6/gosu-armhf /usr/sbin/gosu
WORKDIR /app/gogs/
RUN ./docker/build.sh
+# Configure LibC Name Service
+COPY docker/nsswitch.conf /etc/nsswitch.conf
+
# Configure Docker Container
VOLUME ["/data"]
EXPOSE 22 3000
export PATH=${PATH}:${GOPATH}/bin
# Install build deps
-apk -U --no-progress add linux-pam-dev go@community gcc musl-dev
+apk -U --no-progress add --virtual build-deps linux-pam-dev go@community gcc musl-dev
# Init go environment to build Gogs
mkdir -p ${GOPATH}/src/github.com/gogits/
rm -r $GOPATH
# Remove build deps
-apk --no-progress del linux-pam-dev go gcc musl-dev
+apk --no-progress del build-deps
# Create git user for Gogs
adduser -H -D -g 'Gogs Git User' git -h /data/git -s /bin/bash && passwd -u git
--- /dev/null
+# /etc/nsswitch.conf
+
+passwd: compat
+group: compat
+shadow: compat
+
+hosts: files dns
+networks: files
+
+protocols: db files
+services: db files
+ethers: db files
+rpc: db files
+
+netgroup: nis
+