-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.base
33 lines (27 loc) · 1.53 KB
/
Dockerfile.base
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
ARG CLOUDFLARED_VERSION=2023.5.0
ARG BASEIMAGE="ghcr.io/efrecon/cloudflared:${CLOUDFLARED_VERSION}"
FROM ${BASEIMAGE}
# Root for GitHub, hardly likely to change for a long while...
ARG GITHUB_ROOT=https://github.com
# Metadata
LABEL [email protected]
LABEL org.opencontainers.image.title="sshd-cloudflared-base"
LABEL org.opencontainers.image.description="User-level SSHs tunnelled through cloudflare"
LABEL org.opencontainers.image.authors="Emmanuel Frécon <[email protected]>"
LABEL org.opencontainers.image.url="$GITHUB_ROOT/efrecon/sshd-cloudflared"
LABEL org.opencontainers.image.documentation="$GITHUB_ROOT/efrecon/sshd-cloudflared/README.md"
LABEL org.opencontainers.image.source="$GITHUB_ROOT/efrecon/sshd-cloudflared"
# Install requirements for the script at the requested version. We can now use
# curl for downloads. Also Install minimal init to place all child processes
# under our control. Note: we add bash even though this isn't required. This is
# so it can be provided through the `-s` option. gcompat facilitates running
# glibc binaries and is necessary for mounting the local docker client binary
# into the container. libstdc++, libgcc enable running the VS Code Remote
# Extension against this container.
RUN apk add --no-cache tini openssh jq bash
COPY sshd_config.tpl /usr/local/lib/
COPY entrypoint.sh /usr/local/bin
# Run behind tini, capturing the entire process group to properly teardown all
# subprocesses.
STOPSIGNAL SIGINT
ENTRYPOINT [ "/sbin/tini", "-wgv", "--", "/usr/local/bin/entrypoint.sh" ]