Skip to content

klutchell/balena-tailscale

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

balena-tailscale

Add your device to your Tailscale network with this block!

Usage

To use this block, add a service in your docker-compose.yml file as shown below.

volumes:
  ...
  ts-state: {}

services:
  ...
  tailscale:
    # where <arch> is one of aarch64, armv7hf or amd64
    image: bh.cr/gh_klutchell/tailscale-<arch>
    network_mode: host
    restart: on-failure
    volumes:
      - ts-state:/var/lib/tailscale
    labels:
      - io.balena.features.kernel-modules=1
    cap_add:
      - net_admin
      - sys_module
    tmpfs:
      - /tmp
      - /var/run/

To pin to a specific version of this block use:

services:
  ...
  tailscale:
    # where <version> is the release semver or release commit ID
    image: bh.cr/gh_klutchell/tailscale-<arch>/<version>
    network_mode: host
    restart: on-failure
    volumes:
      - ts-state:/var/lib/tailscale
    labels:
      - io.balena.features.kernel-modules=1
    cap_add:
      - net_admin
      - sys_module
    tmpfs:
      - /tmp
      - /var/run/

Customization

Environment Variables

The supported environment variables are detailed on the official DockerHub repo and on the Using Tailscale with Docker KB.

Serve Config

To expose services via Tailscale Serve or Tailscale Funnel, you can load a custom serve.json file.

FROM bh.cr/gh_klutchell/tailscale-aarch64

COPY serve.json /config/serve.json
# Accepts a JSON file to programmatically configure Serve and Funnel functionality.
# Use tailscale serve status --json to export your current configuration in the correct format.
# https://tailscale.com/kb/1282/docker#ts_serve_config
ENV TS_SERVE_CONFIG="/config/serve.json"

Contributing

Please open an issue or submit a pull request with any features, fixes, or changes.

Acknowledgements

Tailscale is primarily developed by the people at https://github.com/orgs/tailscale/people. For other contributors, see:

These related projects were also used for reference:

Legal

WireGuard is a registered trademark of Jason A. Donenfeld.

About

Run a Tailscale subnet router on balena!

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •