Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define controller networks using the network name #431

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lucaslorentz
Copy link
Owner

@lucaslorentz lucaslorentz commented Nov 28, 2022

Currently, there is only 1 way to configure CDP in distributed mode (controllers + servers):

  • Setting CADDY_CONTROLLER_NETWORK with network CIDR on both controller and servers

What I'm changing:

  • CADDY_CONTROLLER_NETWORK can be configured with the network name when configured in controllers, or completely omitted if the controller is connected to a single network.
  • CADDY_CONTROLLER_NETWORK can be replaced by CADDY_CONTROLLER_URL on servers, and servers will fetch the controller network information from a new endpoint exposed in controllers.
  • When both CADDY_CONTROLLER_NETWORK and CADDY_CONTROLLER_URL are omitted on servers, they will allow configuration from all networks they're connected to.

This simplifies configuration for distributed mode and removes the need to hardcode network CIDRs:

  • When having a single network for ingress and controlling, you don't have to configure any of those settings anymore. Keep in mind that this approach is less secure, as any proxied container will have access to CDP servers' admin endpoints.
  • When separating ingress and controlling networks, the easiest configuration now is setting CADDY_CONTROLLER_NETWORK with the network name in controllers and setting CADDY_CONTROLLER_URL on servers.

Fixes #286

@lucaslorentz lucaslorentz force-pushed the controller-network-name branch 2 times, most recently from c56026b to 2e6a099 Compare November 28, 2022 23:33
@lucaslorentz lucaslorentz marked this pull request as draft November 28, 2022 23:38
@lucaslorentz lucaslorentz changed the title Implement controller network via name Define controller networks using the network name Nov 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can I use the network name instead of IP range to define controller network?
1 participant