diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2020-11-04 16:53:49 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-04 16:53:49 +0100 |
commit | 4fb7378ee4ca2af5d521f7f75b691d4fe00b089b (patch) | |
tree | 6570b9710ca377ed764e3074dc369ef55bc159d8 /libpod/state.go | |
parent | 303191bf522db9af32cabd98a5309e3079da0eb0 (diff) | |
parent | 844d540d042fe7477e62f8cf28e524fcd756f6c8 (diff) | |
download | podman-4fb7378ee4ca2af5d521f7f75b691d4fe00b089b.tar.gz podman-4fb7378ee4ca2af5d521f7f75b691d4fe00b089b.tar.bz2 podman-4fb7378ee4ca2af5d521f7f75b691d4fe00b089b.zip |
Merge pull request #8156 from mheon/add_net_aliases_db
Add network aliases for containers to DB
Diffstat (limited to 'libpod/state.go')
-rw-r--r-- | libpod/state.go | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/libpod/state.go b/libpod/state.go index 44632b02f..183f773b5 100644 --- a/libpod/state.go +++ b/libpod/state.go @@ -98,6 +98,21 @@ type State interface { // returned. AllContainers() ([]*Container, error) + // Get network aliases for the given container in the given network. + GetNetworkAliases(ctr *Container, network string) ([]string, error) + // Get all network aliases for the given container. + GetAllNetworkAliases(ctr *Container) (map[string][]string, error) + // Set network aliases for the given container in the given network. + SetNetworkAliases(ctr *Container, network string, aliases []string) error + // Remove network aliases for the given container in the given network. + RemoveNetworkAliases(ctr *Container, network string) error + // GetAllAliasesForNetwork returns all the aliases for a given + // network. Returns a map of alias to container ID. + GetAllAliasesForNetwork(network string) (map[string]string, error) + // RemoveAllAliasesForNetwork removes all the aliases for a given + // network. + RemoveAllAliasesForNetwork(network string) error + // Return a container config from the database by full ID GetContainerConfig(id string) (*ContainerConfig, error) |