diff options
author | Matthew Heon <matthew.heon@pm.me> | 2020-10-27 15:50:03 -0400 |
---|---|---|
committer | Matthew Heon <matthew.heon@pm.me> | 2020-10-27 15:50:03 -0400 |
commit | 63efde15f14b18f5af385e89936b4ab0868cb357 (patch) | |
tree | e40c8b71e2e24cb3b375e2c2cfd15a835d946fed /libpod/state.go | |
parent | 6af7e544636ae66ce237489ce6948123e1b3249d (diff) | |
download | podman-63efde15f14b18f5af385e89936b4ab0868cb357.tar.gz podman-63efde15f14b18f5af385e89936b4ab0868cb357.tar.bz2 podman-63efde15f14b18f5af385e89936b4ab0868cb357.zip |
Add a way to retrieve all network aliases for a ctr
The original interface only allowed retrieving aliases for a
specific network, not for all networks. This will allow aliases
to be retrieved for every network the container is present in,
in a single DB operation.
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
Diffstat (limited to 'libpod/state.go')
-rw-r--r-- | libpod/state.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libpod/state.go b/libpod/state.go index fca0548c4..6b178ec58 100644 --- a/libpod/state.go +++ b/libpod/state.go @@ -100,6 +100,8 @@ type State interface { // 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. |