1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00
Moby Project - a collaborative project for the container ecosystem to assemble container-based systems
Find a file
Sebastiaan van Stijn e52001c56e
Fix network name masking network ID on delete
If a network is created with a name that matches another
network's ID, the network with that name was masking the
other network's ID.

As a result, it was not possible to remove the network
with a given ID.

This patch changes the order in which networks are
matched to be what we use for other cases;

1. Match on full ID
2. Match on full Name
3. Match on Partial ID

Before this patch:

    $ docker network create foo
    336717eac9eaa3da6557042a04efc803f7e8862ce6cf96f6b9565265ba5c618b

    $ docker network create 336717eac9eaa3da6557042a04efc803f7e8862ce6cf96f6b9565265ba5c618b
    4a698333f1197f20224583abce14876d7f25fdfe416a8545927006c315915a2a

    $ docker network ls
    NETWORK ID          NAME                                                               DRIVER              SCOPE
    4a698333f119        336717eac9eaa3da6557042a04efc803f7e8862ce6cf96f6b9565265ba5c618b   bridge              local
    d1e40d43a2c0        bridge                                                             bridge              local
    336717eac9ea        foo                                                                bridge              local
    13cf280a1bbf        host                                                               host                local
    d9e4c03728a0        none                                                               null                local

    $ docker network rm 336717eac9eaa3da6557042a04efc803f7e8862ce6cf96f6b9565265ba5c618b
    4a698333f1197f20224583abce14876d7f25fdfe416a8545927006c315915a2a

    $ docker network ls
    NETWORK ID          NAME                DRIVER              SCOPE
    d1e40d43a2c0        bridge              bridge              local
    336717eac9ea        foo                 bridge              local
    13cf280a1bbf        host                host                local
    d9e4c03728a0        none                null                local

After this patch:

    $ docker network create foo
    2d1791a7def4e2a1ef0f6b83c6add333df0bb4ced2f196c584cb64e6bd94b835

    $ docker network create 2d1791a7def4e2a1ef0f6b83c6add333df0bb4ced2f196c584cb64e6bd94b835
    6cbc749a529cd2d9d3b10566c84e56c4203dd88b67417437b5fc7a6e955dd48f

    $ docker network ls
    NETWORK ID          NAME                                                               DRIVER              SCOPE
    6cbc749a529c        2d1791a7def4e2a1ef0f6b83c6add333df0bb4ced2f196c584cb64e6bd94b835   bridge              local
    166c943dbeb5        bridge                                                             bridge              local
    2d1791a7def4        foo                                                                bridge              local
    6c45b8aa6d8e        host                                                               host                local
    b11c96b51ea7        none                                                               null                local

    $ docker network rm 2d1791a7def4e2a1ef0f6b83c6add333df0bb4ced2f196c584cb64e6bd94b835
    2d1791a7def4e2a1ef0f6b83c6add333df0bb4ced2f196c584cb64e6bd94b835

    $ docker network ls
    NETWORK ID          NAME                                                               DRIVER              SCOPE
    6cbc749a529c        2d1791a7def4e2a1ef0f6b83c6add333df0bb4ced2f196c584cb64e6bd94b835   bridge              local
    166c943dbeb5        bridge                                                             bridge              local
    6c45b8aa6d8e        host                                                               host                local
    b11c96b51ea7        none                                                               null                local

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2017-10-11 21:57:05 +02:00
.github Fix GitHub spelling 2017-10-07 00:10:24 +08:00
api Merge pull request #35150 from thaJeztah/fix-api-version-check 2017-10-11 11:26:12 -07:00
builder Merge pull request #35138 from vdemeester/foo 2017-10-09 12:16:16 -07:00
cli
client Merge pull request #35128 from thaJeztah/fix-ContainerExecAttach-type 2017-10-10 10:59:16 -07:00
cmd/dockerd LCOW: API: Add platform to /images/create and /build 2017-10-06 11:44:18 -07:00
container LCOW: API change JSON header to string POST parameter 2017-10-06 15:26:48 -07:00
contrib Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
daemon Fix network name masking network ID on delete 2017-10-11 21:57:05 +02:00
distribution Stop filtering Windows manifest lists by version 2017-10-06 22:37:31 -07:00
dockerversion
docs Fix network name masking network ID on delete 2017-10-11 21:57:05 +02:00
hack Merge pull request #34941 from dsheets/authz-tests-api-port 2017-10-11 16:15:56 +02:00
image LCOW: API change JSON header to string POST parameter 2017-10-06 15:26:48 -07:00
integration Fix network name masking network ID on delete 2017-10-11 21:57:05 +02:00
integration-cli Merge pull request #34941 from dsheets/authz-tests-api-port 2017-10-11 16:15:56 +02:00
internal Docker EE integration test fixes 2017-09-25 18:09:19 +02:00
layer LCOW: API: Add platform to /images/create and /build 2017-10-06 11:44:18 -07:00
libcontainerd
migrate/v1 LCOW: API: Add platform to /images/create and /build 2017-10-06 11:44:18 -07:00
oci
opts
pkg Merge pull request #33488 from raja-sami-10p/pkg/idtools 2017-10-10 18:37:49 +02:00
plugin Refactor plugin store to reduce nested if's in Get 2017-10-09 22:21:27 +03:00
profiles drop useless apparmor denies 2017-10-06 09:11:59 -06:00
project Fix GitHub spelling 2017-10-07 00:10:24 +08:00
reference
registry
reports
restartmanager
runconfig
vendor Merge pull request #34758 from ghislainbourgeois/33495-add-tcp-to-gelf-log-driver 2017-10-10 10:26:01 -04:00
volume Merge pull request #34792 from runcom/fix-relabel-symlinks 2017-09-27 17:42:23 +02:00
.dockerignore
.gitignore
.mailmap Update mailmap and authors 2017-10-04 14:44:24 +02:00
AUTHORS Update mailmap and authors 2017-10-04 14:44:24 +02:00
CHANGELOG.md
CONTRIBUTING.md
Dockerfile Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.aarch64 Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.armhf Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.e2e Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.ppc64le Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.s390x Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.simple Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
Dockerfile.solaris
Dockerfile.windows Bump Go to 1.8.4 2017-10-04 23:22:23 +02:00
LICENSE
MAINTAINERS Fix GitHub spelling 2017-10-07 00:10:24 +08:00
Makefile Add a new entrypoint for CI 2017-09-20 17:26:30 -04:00
NOTICE
poule.yml
README.md Add "Lego set" back in README.md 2017-10-10 14:10:39 +00:00
ROADMAP.md Update the Roadmap 2017-10-11 17:33:50 +01:00
TESTING.md
vendor.conf Merge pull request #34758 from ghislainbourgeois/33495-add-tcp-to-gelf-log-driver 2017-10-10 10:26:01 -04:00
VENDORING.md
VERSION

The Moby Project

Moby Project logo

Moby is an open-source project created by Docker to enable and accelerate software containerization.

It provides a "Lego set" of toolkit components, the framework for assembling them into custom container-based systems, and a place for all container enthusiasts and professionals to experiment and exchange ideas. Components include container build tools, a container registry, orchestration tools, a runtime and more, and these can be used as building blocks in conjunction with other tools and projects.

Principles

Moby is an open project guided by strong principles, aiming to be modular, flexible and without too strong an opinion on user experience. It is open to the community to help set its direction.

  • Modular: the project includes lots of components that have well-defined functions and APIs that work together.
  • Batteries included but swappable: Moby includes enough components to build fully featured container system, but its modular architecture ensures that most of the components can be swapped by different implementations.
  • Usable security: Moby provides secure defaults without compromising usability.
  • Developer focused: The APIs are intended to be functional and useful to build powerful tools. They are not necessarily intended as end user tools but as components aimed at developers. Documentation and UX is aimed at developers not end users.

Audience

The Moby Project is intended for engineers, integrators and enthusiasts looking to modify, hack, fix, experiment, invent and build systems based on containers. It is not for people looking for a commercially supported system, but for people who want to work and learn with open source code.

Relationship with Docker

The components and tools in the Moby Project are initially the open source components that Docker and the community have built for the Docker Project. New projects can be added if they fit with the community goals. Docker is committed to using Moby as the upstream for the Docker Product. However, other projects are also encouraged to use Moby as an upstream, and to reuse the components in diverse ways, and all these uses will be treated in the same way. External maintainers and contributors are welcomed.

The Moby project is not intended as a location for support or feature requests for Docker products, but as a place for contributors to work on open source code, fix bugs, and make the code more useful. The releases are supported by the maintainers, community and users, on a best efforts basis only, and are not intended for customers who want enterprise or commercial support; Docker EE is the appropriate product for these use cases.


Legal

Brought to you courtesy of our legal counsel. For more context, please see the NOTICE document in this repo.

Use and transfer of Moby may be subject to certain restrictions by the United States and other governments.

It is your responsibility to ensure that your use and/or transfer does not violate applicable laws.

For more information, please see https://www.bis.doc.gov

Licensing

Moby is licensed under the Apache License, Version 2.0. See LICENSE for the full license text.