feat: add tailscale example image

This commit is contained in:
Ben Potter 2021-10-20 17:40:18 +00:00
parent d6df18c3d3
commit dd333ee980
No known key found for this signature in database
GPG Key ID: C39EC065353E70F2
6 changed files with 41 additions and 0 deletions

View File

@ -0,0 +1,22 @@
FROM codercom/enterprise-base:ubuntu
USER root
# Copy configuration files to appropriate locations
COPY files /
ARG DEBIAN_FRONTEND="noninteractive"
RUN apt-get update && \
apt-get install --no-install-recommends --yes --quiet \
netcat-openbsd \
proxychains4 \
python3 && \
apt-get install --no-install-recommends --yes --quiet \
tailscale && \
# Delete package cache to avoid consuming space in layer
apt-get clean && \
rm -rf /var/lib/apt/lists/*
USER coder
ENV ALL_PROXY=socks5://localhost:1080
ENV http_proxy=http://localhost:3128

View File

@ -0,0 +1,7 @@
# enterprise-tailscale
An image with [Tailscale networking](https://tailscale.com/) installed for use inside
Coder workspaces, so that you can access services running inside Coder as well
as other services running on your [tailnet (Tailscale private network)](https://tailscale.com/kb/1136/tailnet/).
See the guide in our docs for more details: <https://coder.com/docs/coder/latest/customization/tailscale>

View File

@ -0,0 +1,7 @@
# Ignore all packages from this repository by default
Package: *
Pin: origin pkgs.tailscale.com
Pin-Priority: 1
Package: tailscale
Pin: origin pkgs.tailscale.com
Pin-Priority: 500

View File

@ -0,0 +1,2 @@
# Tailscale packages for ubuntu focal
deb [signed-by=/usr/share/keyrings/tailscale.gpg] https://pkgs.tailscale.com/stable/ubuntu focal main

View File

@ -0,0 +1,3 @@
[Service]
ExecStart=
ExecStart=-/usr/sbin/tailscaled --state=/home/coder/.config/tailscaled.state --socket=/var/run/tailscale/tailscaled.sock --port $PORT --tun=userspace-networking --socks5-server=localhost:1080 --outbound-http-proxy-listen=localhost:3128 $FLAGS