mirror of
https://github.com/psviderski/uncloud.git
synced 2026-08-26 19:13:34 +00:00
docs: add info that caddy could be deployed on specific machines
This commit is contained in:
@@ -9,8 +9,8 @@ with [Let's Encrypt](https://letsencrypt.org/), and route requests to your servi
|
|||||||
|
|
||||||
## How it works
|
## How it works
|
||||||
|
|
||||||
Caddy runs as a global service `caddy` on every machine in your cluster, listening on the host ports 80 (HTTP) and 443
|
By default, Caddy runs as a global service `caddy` on every machine in your cluster, listening on the host ports 80
|
||||||
(HTTPS).
|
(HTTP) and 443 (HTTPS).
|
||||||
|
|
||||||
It's deployed during cluster initialisation (`uc machine init`) unless you use the `--no-caddy` flag.
|
It's deployed during cluster initialisation (`uc machine init`) unless you use the `--no-caddy` flag.
|
||||||
See [Managing Caddy](3-managing-caddy.md) for deployment and customisation instructions.
|
See [Managing Caddy](3-managing-caddy.md) for deployment and customisation instructions.
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# Managing Caddy
|
# Managing Caddy
|
||||||
|
|
||||||
Caddy is automatically deployed as a global service `caddy` when you initialise a cluster with `uc machine init`. It
|
Caddy is automatically deployed as a global service `caddy` when you initialise a cluster with `uc machine init`. By
|
||||||
runs on every machine to handle incoming HTTP/HTTPS traffic and route it to your services.
|
default, it runs on every machine to handle incoming HTTP/HTTPS traffic and route it to your services.
|
||||||
|
|
||||||
## Checking status
|
## Checking status
|
||||||
|
|
||||||
@@ -37,6 +37,13 @@ Deploy a specific version or custom image:
|
|||||||
uc caddy deploy --image caddybuilds/caddy-cloudflare:2.10.2
|
uc caddy deploy --image caddybuilds/caddy-cloudflare:2.10.2
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Deploy only to a specific machine or a subset of machines (comma-separated list):
|
||||||
|
|
||||||
|
```shell
|
||||||
|
uc caddy deploy --machine machine1
|
||||||
|
uc caddy deploy --machine machine2,machine3,machine4
|
||||||
|
```
|
||||||
|
|
||||||
Deploy with custom global configuration:
|
Deploy with custom global configuration:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
@@ -90,6 +97,10 @@ services:
|
|||||||
x-caddy: Caddyfile
|
x-caddy: Caddyfile
|
||||||
deploy:
|
deploy:
|
||||||
mode: global
|
mode: global
|
||||||
|
# Optional: deploy only to specific machines.
|
||||||
|
# x-machines:
|
||||||
|
# - machine1
|
||||||
|
# - machine2
|
||||||
```
|
```
|
||||||
|
|
||||||
</TabItem>
|
</TabItem>
|
||||||
@@ -139,8 +150,8 @@ uc deploy
|
|||||||
|
|
||||||
## Verifying config
|
## Verifying config
|
||||||
|
|
||||||
View the complete generated Caddyfile served by the `caddy` service. This is useful for debugging and verifying
|
View the complete generated Caddyfile served by the `caddy` service. This is useful for debugging and verifying custom
|
||||||
custom global and service-specific Caddy configs.
|
global and service-specific Caddy configs.
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
uc caddy config
|
uc caddy config
|
||||||
|
|||||||
Reference in New Issue
Block a user