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

[25.0 backport] Don't enforce new validation rules for existing networks #47482

Merged
merged 1 commit into from Mar 1, 2024

Commits on Mar 1, 2024

  1. Don't enforce new validation rules for existing networks

    Non-swarm networks created before network-creation-time validation
    was added in 25.0.0 continued working, because the checks are not
    re-run.
    
    But, swarm creates networks when needed (with 'agent=true'), to
    ensure they exist on each agent - ignoring the NetworkNameError
    that says the network already existed.
    
    By ignoring validation errors on creation of a network with
    agent=true, pre-existing swarm networks with IPAM config that would
    fail the new checks will continue to work too.
    
    New swarm (overlay) networks are still validated, because they are
    initially created with 'agent=false'.
    
    Signed-off-by: Rob Murray <rob.murray@docker.com>
    (cherry picked from commit 571af91)
    Signed-off-by: Albin Kerouanton <albinker@gmail.com>
    robmry authored and akerouanton committed Mar 1, 2024
    Configuration menu
    Copy the full SHA
    1ae019f View commit details
    Browse the repository at this point in the history