File tree Expand file tree Collapse file tree 5 files changed +46
-0
lines changed Expand file tree Collapse file tree 5 files changed +46
-0
lines changed Original file line number Diff line number Diff line change 1+ # # Image name: faucet/base
2+
3+ FROM alpine:3.7
4+ RUN apk add --no-cache bash su-exec
5+ COPY entrypoint.sh /usr/local/bin/entrypoint.sh
6+ ENTRYPOINT ["/usr/local/bin/entrypoint.sh" ]
Original file line number Diff line number Diff line change 1+ ## Image name: faucet/base-pi
2+
3+ FROM multiarch/alpine:armhf-v3.7
4+ RUN apk add --no-cache bash su-exec
5+ COPY entrypoint.sh /usr/local/bin/entrypoint.sh
6+ ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
Original file line number Diff line number Diff line change 1+ Faucet Base Docker Image
2+ ========================
3+
4+ This is the base image used for many of the other Docker images for the
5+ `faucet project <https://faucet.nz >`_.
6+
7+ Pull from Docker Hub
8+ --------------------
9+
10+ Built images are available on Docker Hub so that you don't need to build your own.
11+
12+ Images are available for the following architectures:
13+
14+ * `amd64 <https://hub.docker.com/r/faucet/base/ >`_
15+ * `armhf (for raspberry pi) <https://hub.docker.com/r/faucet/base-pi/ >`_
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ # Add local user
4+ # Either use the LOCAL_USER_ID if passed in at runtime or
5+ # fallback to 0 to maintain backwards compatibility
6+
7+ USER_ID=${LOCAL_USER_ID:- 0}
8+ GROUP_ID=${LOCAL_GROUP_ID:- 0}
9+
10+ echo " Starting with UID=$USER_ID GID=$GROUP_ID "
11+ export HOME=/home/faucet
12+ addgroup -g $GROUP_ID faucet > /dev/null 2>&1 || true
13+ adduser -u $USER_ID -G faucet -g " " -h $HOME -D faucet > /dev/null 2>&1 || true
14+
15+ exec /sbin/su-exec faucet " $@ "
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ # We need qemu-user-static for arm/pi builds
4+ docker run --rm --privileged multiarch/qemu-user-static:register --reset
You can’t perform that action at this time.
0 commit comments