Interface Manager
-
- All Known Implementing Classes:
DockerManager
public interface Manager
The interface Manager.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
buildImage(File dockerfile, Set<String> tag)
Build image.void
connectContainerToNetwork(Container container, Network network)
Connect container to network.Container
createContainer(String name, String tag)
Create container container.Network
createNetwork(String name, String subnet)
Create network network.void
deleteImage(String tag)
Delete image.void
destroyContainer(Container container)
Destroy container.void
destroyNetwork(Network network)
Destroy network.void
disconnectContainer(Container container, Network network)
Disconnects container from network.String
findIpAddress(Container container, Network network)
Find ip address string.void
killContainer(Container container)
Method stops container.List<Container>
listContainers()
List containers list.List<Network>
listNetworks()
List networks list.void
runCommand(Container container, String command)
Run command.void
startContainer(Container container)
Start container.
-
-
-
Method Detail
-
createContainer
Container createContainer(String name, String tag)
Create container container.- Parameters:
name
- the nametag
- the tag- Returns:
- the container
-
findIpAddress
String findIpAddress(Container container, Network network)
Find ip address string.- Parameters:
container
- the containernetwork
- the network- Returns:
- the string
-
createNetwork
Network createNetwork(String name, String subnet)
Create network network.- Parameters:
name
- the namesubnet
- the subnet- Returns:
- the network
-
connectContainerToNetwork
void connectContainerToNetwork(Container container, Network network)
Connect container to network.- Parameters:
container
- the containernetwork
- the network
-
killContainer
void killContainer(Container container)
Method stops container.- Parameters:
container
-
-
disconnectContainer
void disconnectContainer(Container container, Network network)
Disconnects container from network.- Parameters:
container
-network
-
-
destroyContainer
void destroyContainer(Container container)
Destroy container.- Parameters:
container
- the container
-
destroyNetwork
void destroyNetwork(Network network)
Destroy network.- Parameters:
network
- the network
-
runCommand
void runCommand(Container container, String command)
Run command.- Parameters:
container
- the containercommand
- the command
-
startContainer
void startContainer(Container container)
Start container.- Parameters:
container
- the container
-
buildImage
void buildImage(File dockerfile, Set<String> tag)
Build image.- Parameters:
dockerfile
- the dockerfiletag
- the tag
-
deleteImage
void deleteImage(String tag)
Delete image.- Parameters:
tag
- the tag
-
-