|
typedef std::function< int()> | ExecFunction |
|
|
virtual const char * | id () const =0 |
|
virtual bool | initialize ()=0 |
|
virtual bool | create ()=0 |
|
virtual bool | start (pid_t *pid)=0 |
|
virtual bool | stop ()=0 |
|
virtual bool | shutdown ()=0 |
|
virtual bool | shutdown (unsigned int timeout)=0 |
|
virtual bool | suspend ()=0 |
|
virtual bool | resume ()=0 |
|
virtual bool | destroy ()=0 |
|
virtual bool | destroy (unsigned int timeout)=0 |
|
virtual bool | mountDevice (const std::string &pathInHost)=0 |
|
virtual bool | bindMountInContainer (const std::string &pathInHost, const std::string &pathInContainer, bool readOnly=true)=0 |
| Tries to bind mount a path from host to container. More...
|
|
virtual bool | setEnvironmentVariable (const std::string &variable, const std::string &value)=0 |
|
virtual bool | setCgroupItem (std::string subsys, std::string value)=0 |
|
virtual bool | execute (ExecFunction function, pid_t *pid, const EnvironmentVariables &variables=EnvironmentVariables(), int stdin=-1, int stdout=-1, int stderr=2)=0 |
| Executes a commandline. More...
|
|
virtual bool | execute (const std::string &commandLine, pid_t *pid, const EnvironmentVariables &variables=EnvironmentVariables(), const std::string &workingDirectory="/", int stdin=-1, int stdout=1, int stderr=2)=0 |
| Executes a function. More...
|
|
virtual bool softwarecontainer::ContainerAbstractInterface::bindMountInContainer |
( |
const std::string & |
pathInHost, |
|
|
const std::string & |
pathInContainer, |
|
|
bool |
readOnly = true |
|
) |
| |
|
pure virtual |
Tries to bind mount a path from host to container.
Any missing parent paths will be created.
- Parameters
-
pathInHost | The path on the host that shall be bind mounted into the container |
pathInContainer | Where to mount the path in the container. |
readonly | Sets if the mount should be read only or read write |
- Returns
- true if everything worked as expected, false otherwise
Implemented in softwarecontainer::Container.
virtual bool softwarecontainer::Executable::execute |
( |
ExecFunction |
function, |
|
|
pid_t * |
pid, |
|
|
const EnvironmentVariables & |
variables = EnvironmentVariables() , |
|
|
int |
stdin = -1 , |
|
|
int |
stdout = -1 , |
|
|
int |
stderr = 2 |
|
) |
| |
|
pure virtualinherited |
virtual bool softwarecontainer::Executable::execute |
( |
const std::string & |
commandLine, |
|
|
pid_t * |
pid, |
|
|
const EnvironmentVariables & |
variables = EnvironmentVariables() , |
|
|
const std::string & |
workingDirectory = "/" , |
|
|
int |
stdin = -1 , |
|
|
int |
stdout = 1 , |
|
|
int |
stderr = 2 |
|
) |
| |
|
pure virtualinherited |
The documentation for this class was generated from the following file: