{%= description %}
HigherDockerManager is built on top of node-docker-api offering some higher-order management functions. node-docker-api
is not included as dependency but referenced as a peer dependency.
Install with npm:
$ npm install --save higher-docker-manager node-docker-api@^1.1.2
const HigherDockerManager = require('{%= name %}');
return HigherDockerManager.pullImage({}, 'hello-world:latest')
.then(() => HigherDockerManager.runTemporaryContainer({
image: 'hello-world:latest'
}))
.then((output) => {
assert(_.isArray(output));
assert(output[1].payload, 'Hello from Docker!\n');
});
- Pulling an image from a repository
- Finding process's own container if its running in Docker
- Running a temporary container
- Executing a command in a running container
- Finding containers by networks, labels and images
- Finding volumes by labels and their values
- Finding networks by labels and their values
{%= apidocs("lib/higher-docker-manager.js") %}
{%= section("related", related(verb.related.list)) %}
{%= includeEither("authors", "author") %}
{%= include("contributing") %}
{%= include("CHANGELOG.md") %}
{%= copyright({linkify: true, prefix: "Copyright", symbol: "©"}) %} {%= before.license ? (before.license + "\n") : "" %}{%= license %}{%= after.license ? (after.license + "\n") : "" %}
{%= include("footer") %}