From 18867a4c8404acf9d60e752bee9c555451007de1 Mon Sep 17 00:00:00 2001 From: ohdearaugustin Date: Sun, 12 Sep 2021 18:08:03 +0200 Subject: [PATCH] update docu --- README.md | 28 ++++++++++++++++++++++++++-- k8s/README.md | 1 - 2 files changed, 26 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index cb42b666..c13a5fcc 100644 --- a/README.md +++ b/README.md @@ -39,8 +39,16 @@ Suggestions/PRs welcomed! ## Running it -1. Download the Headscale binary https://github.com/juanfont/headscale/releases, and place it somewhere in your PATH - +1. Download the Headscale binary https://github.com/juanfont/headscale/releases, and place it somewhere in your PATH or use the docker container + + ```shell + docker pull headscale/headscale:x.x.x + ``` + + or + ```shell + docker pull ghrc.io/juanfont/headscale:x.x.x + ``` 2. (Optional, you can also use SQLite) Get yourself a PostgreSQL DB running @@ -65,11 +73,19 @@ Suggestions/PRs welcomed! ```shell headscale namespaces create myfirstnamespace ``` + or docker: + ```shell + docker run -v ./private.key:/private.key -v ./config.json:/config.json headscale/headscale:x.x.x headscale namespace create myfirstnamespace + ``` 5. Run the server ```shell headscale serve ``` + or docker: + ```shell + docker run -v $(pwd)/private.key:/private.key -v $(pwd)/config.json:/config.json -v $(pwd)/derb.yaml:/derb.yaml -p 127.0.0.1:8080:8080 headscale/headscale:x.x.x headscale serve + ``` 6. If you used tailscale.com before in your nodes, make sure you clear the tailscaled data folder ```shell @@ -89,6 +105,10 @@ Suggestions/PRs welcomed! ```shell headscale -n myfirstnamespace node register YOURMACHINEKEY ``` + or docker: + ```shell + docker run -v ./private.key:/private.key -v ./config.json:/config.json headscale/headscale:x.x.x headscale -n myfirstnamespace node register YOURMACHINEKEY + ``` Alternatively, you can use Auth Keys to register your machines: @@ -96,6 +116,10 @@ Alternatively, you can use Auth Keys to register your machines: ```shell headscale -n myfirstnamespace preauthkeys create --reusable --expiration 24h ``` + or docker: + ```shell + docker run -v ./private.key:/private.key -v ./config.json:/config.json headscale/headscale:x.x.x headscale -n myfirstnamespace preauthkeys create --reusable --expiration 24h + ``` 2. Use the authkey from your machine to register it ```shell diff --git a/k8s/README.md b/k8s/README.md index 0f60794c..2f187abb 100644 --- a/k8s/README.md +++ b/k8s/README.md @@ -89,7 +89,6 @@ Use "headscale [command] --help" for more information about a command. # TODO / Ideas -- Github action to publish the docker image - Interpolate `email:` option to the ClusterIssuer from site configuration. This probably needs to be done with a transformer, kustomize vars don't seem to work. - Add kustomize examples for cloud-native ingress, load balancer