You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tailscale/cmd/containerboot
Tom Proctor 24095e4897
cmd/containerboot: serve health on local endpoint (#14246)
* cmd/containerboot: serve health on local endpoint

We introduced stable (user) metrics in #14035, and `TS_LOCAL_ADDR_PORT`
with it. Rather than requiring users to specify a new addr/port
combination for each new local endpoint they want the container to
serve, this combines the health check endpoint onto the local addr/port
used by metrics if `TS_ENABLE_HEALTH_CHECK` is used instead of
`TS_HEALTHCHECK_ADDR_PORT`.

`TS_LOCAL_ADDR_PORT` now defaults to binding to all interfaces on 9002
so that it works more seamlessly and with less configuration in
environments other than Kubernetes, where the operator always overrides
the default anyway. In particular, listening on localhost would not be
accessible from outside the container, and many scripted container
environments do not know the IP address of the container before it's
started. Listening on all interfaces allows users to just set one env
var (`TS_ENABLE_METRICS` or `TS_ENABLE_HEALTH_CHECK`) to get a fully
functioning local endpoint they can query from outside the container.

Updates #14035, #12898

Signed-off-by: Tom Proctor <tomhjp@users.noreply.github.com>
1 year ago
..
forwarding.go cmd/containerboot,util/linuxfw: create a SNAT rule for dst/src only once, clean up if needed (#13658) 1 year ago
healthz.go cmd/containerboot: serve health on local endpoint (#14246) 1 year ago
kube.go kube/{kubeapi,kubeclient},ipn/store/kubestore,cmd/{containerboot,k8s-operator}: emit kube store Events (#14112) 1 year ago
kube_test.go kube,cmd/{k8s-operator,containerboot},envknob,ipn/store/kubestore,*/depaware.txt: rename packages (#13418) 1 year ago
main.go cmd/containerboot: serve health on local endpoint (#14246) 1 year ago
main_test.go cmd/containerboot: serve health on local endpoint (#14246) 1 year ago
metrics.go cmd/containerboot: serve health on local endpoint (#14246) 1 year ago
serve.go cmd/containerboot: split main.go (#13517) 1 year ago
services.go kube/{kubeapi,kubeclient},ipn/store/kubestore,cmd/{containerboot,k8s-operator}: emit kube store Events (#14112) 1 year ago
services_test.go cmd/containerboot,kube,util/linuxfw: configure kube egress proxies to route to 1+ tailnet targets (#13531) 1 year ago
settings.go cmd/containerboot: serve health on local endpoint (#14246) 1 year ago
tailscaled.go cmd/{containerboot,k8s-operator},k8s-operator: new options to expose user metrics (#14035) 1 year ago
test_tailscale.sh cmd/containerboot: make a tests table, add more tests. 3 years ago
test_tailscaled.sh cmd/containerboot: avoid leaking bash scripts after test runs 2 years ago