You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+22-5Lines changed: 22 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -449,17 +449,21 @@ Each caddy docker proxy instance can be executed in one of the following modes.
449
449
450
450
Acts as a proxy to your Docker resources. The server starts without any configuration, and will not serve anything until it is configured by a "controller".
451
451
452
-
In order to make a server discoverable and configurable by controllers, you need to mark it with label `caddy_controlled_server` and define the controller network via CLI option `controller-network` or environment variable `CADDY_CONTROLLER_NETWORK`.
452
+
In order to make a server discoverable and configurable by controllers, you need to mark it with label `caddy_controlled_server`.
453
453
454
454
Server instances doesn't need access to Docker host socket and you can run it in manager or worker nodes.
When using a separate controller network, you must also configure the controller url via CLI option `controller-url` or environment variable `CADDY_CONTROLLER_URL`, that allows caddy server fetch the controller networks configured in the controller.
Controller monitors your Docker cluster, generates Caddy configuration and pushes to all servers it finds in your Docker cluster.
461
465
462
-
When controller instances are connected to more than one network, it is also necessary to define the controller network via CLI option `controller-network` or environment variable `CADDY_CONTROLLER_NETWORK`.
466
+
When controller instances are connected to more than one network, it is also necessary to define the controller network via CLI option `controller-network` or environment variable `CADDY_CONTROLLER_NETWORK` with the network name.
463
467
464
468
Controller instances require access to Docker host socket.
465
469
@@ -482,29 +486,42 @@ Run `caddy help docker-proxy` to see all available flags.
482
486
```
483
487
Usage of docker-proxy:
484
488
--caddyfile-path string
485
-
Path to a base Caddyfile that will be extended with Docker sites
489
+
Path to a base Caddyfile that will be extended with Docker sites.
490
+
Applicable to modes: controller, standalone
486
491
--controller-network string
487
-
Network allowed to configure Caddy server in CIDR notation. Ex: 10.200.200.0/24
492
+
Controller network name. Ex: caddy_controller.
493
+
Applicable to modes: controller
494
+
--controller-url string
495
+
Controller url, used by servers to fetch controller subnets. Ex: http://caddy-controller
496
+
Applicable to modes: server
488
497
--ingress-networks string
489
498
Comma separated name of ingress networks connecting Caddy servers to containers.
490
499
When not defined, networks attached to controller container are considered ingress networks
500
+
Applicable to modes: controller, standalone
491
501
--docker-sockets
492
502
Comma separated docker sockets
493
503
When not defined, DOCKER_HOST (or default docker socket if DOCKER_HOST not defined)
504
+
Applicable to modes: controller, standalone
494
505
--docker-certs-path
495
506
Comma separated cert path, you could use empty value when no cert path for the concern index docker socket like cert_path0,,cert_path2
507
+
Applicable to modes: controller, standalone
496
508
--docker-apis-version
497
509
Comma separated apis version, you could use empty value when no api version for the concern index docker socket like cert_path0,,cert_path2
510
+
Applicable to modes: controller, standalone
498
511
--label-prefix string
499
512
Prefix for Docker labels (default "caddy")
513
+
Applicable to modes: controller, standalone
500
514
--mode
501
515
Which mode this instance should run: standalone | controller | server
502
516
--polling-interval duration
503
517
Interval Caddy should manually check Docker for a new Caddyfile (default 30s)
518
+
Applicable to modes: controller, standalone
504
519
--process-caddyfile
505
520
Process Caddyfile before loading it, removing invalid servers (default true)
521
+
Applicable to modes: controller, standalone
506
522
--proxy-service-tasks
507
523
Proxy to service tasks instead of service load balancer (default true)
524
+
Applicable to modes: controller, standalone
508
525
```
509
526
510
527
Those flags can also be set via environment variables:
0 commit comments