Security News
Bun 1.2 Released with 90% Node.js Compatibility and Built-in S3 Object Support
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
harbor-master
Advanced tools
Harbor Master is a Docker Remote API client written in Node. This client is meant to be a simple wrapper that makes it easy to communicate with your Docker Daemon over the unix socket or http based APIs.
This project is still in active development. This project will be versioned in accordance with the Docker Remote API. For example, if the current Docker Remote API version is 1.24
, Harbor Master's version will be 1.24.x
.
const docker = require('../index');
const client = docker.Client({
socket: '/var/run/docker.sock'
});
client.info().then((info) => {
console.log(info);
}).catch((err) => {
console.error(err);
});
const docker = require('../index');
const client = docker.Client({
host: 'swarm.example.com',
port: '2375'
});
client.info().then((info) => {
console.log(info);
}).catch((err) => {
console.error(err);
});
const docker = require('../index');
const client = docker.Client({
host: 'swarm.example.com',
port: '2376',
tls: {
ca: fs.readFileSync('ca.pem'),
cert: fs.readFileSync('cert.pem'),
key: fs.readFileSync('key.pem'),
passphrase: 'supersecretpass'
}
});
client.info().then((info) => {
console.log(info);
}).catch((err) => {
console.error(err);
});
docker.Client(options)
- Harbor Master Clientoptions
host
- the IP address or Hostname of the Docker serverport
- the port number the Docker server exposessocket
- the unix sockettls
cert
- contents of the server certificatekey
- contents of the server certificate keyca
- contents of the CA certificatepassword
- the certificate passwordclient.containers().list(options)
- List Containersoptions
all
- default: false
Show all containers. Only running containers are shown by default.limit
- Show limit last created containers, include non-running ones.since
- Show only containers created since Id, include non-running ones.before
- Show only containers created before Id, include non-running ones.size
- default: false
Show the containers sizesfilters
- map[string][]string
to process on the containers listclient.containers().create(model, options)
- Create Containermodel
- the JSON model that the Docker API consumesoptions
name
- Assign the specified name to the container. Must match /?[a-zA-Z0-9_-]+
.client.containers().inspect(name, options)
- Inspect Containername
- the name or id of the containeroptions
size
- default: false
Show the containers sizesclient.containers().top(name)
- List Processes Running Inside a Containername
- the name or id of the containeroptions
ps_args
- ps
arguments to use (e.g., aux), defaults to -ef
client.containers().logs(name, options)
- Container Logsname
- the name or id of the containeroptions
details
- Show extra details provided to logs. default: false
follow
- return stream. default: false
stdout
- show stdout log. default: false
stderr
- show stderr log. default: false
since
- Specifying a timestamp will only output log-entries since that timestamp. default: false
timestamps
- print timestamps for every log line default: false
tail
- Output specified number of lines at the end of logs: all or default: all
client.containers().changes(name, options)
- Inspect Container Filesystem Changesname
- the name or id of the containeroptions
client.containers().export(name, options)
- Export a Containername
- the name or id of the containeroptions
client.containers().stats(name, options)
- Export a Containername
- the name or id of the containeroptions
stream
- stream statistics default: true
client.containers().resize(name, options)
- Resize a container TTYname
- the name or id of the containeroptions
h
- heightw
- widthclient.containers().start(name, options)
- Start a Containername
- the name or id of the containeroptions
detachKeys
- Override the key sequence for detaching a container. Format is a single character.client.containers().stop(name, options)
- Stop a Containername
- the name or id of the containeroptions
t
- number of seconds to wait before killing the containerclient.containers().restart(name, options)
- Restart a Containername
- the name or id of the containeroptions
t
- number of seconds to wait before killing the containerclient.containers().kill(name, options)
- Kill a Containername
- the name or id of the containeroptions
signal
- Signal to send to the container: integer or string like SIGINT. When not set, SIGKILL is assumed and the call waits for the container to exit.client.containers().update(name, model, options)
- Update a Containername
- the name or id of the containermodel
- the JSON model that the Docker API consumesoptions
client.containers().rename(name, options)
- Rename a Containername
- the name or id of the containeroptions
name
- new name for the containerclient.containers().pause(name)
- Pause a Containername
- the name or id of the containeroptions
client.containers().unpause(name)
- Unpause a Containername
- the name or id of the containeroptions
client.containers().attach(name, options)
- Attach a Containername
- the name or id of the containeroptions
detachKeys
- Override the key sequence for detaching a container. Format is a single characterlogs
- return logs default: false
stream
- return stream default: false
stdin
- return stdin default: false
stdout
- return stdout default: false
stderr
- return stderr default: false
client.containers().unpause(name, options)
- Wait a Containername
- the name or id of the containeroptions
client.containers().remove(name, options)
- Wait a Containername
- the name or id of the containeroptions
v
- Remove the volumes associated to the container default: false
force
- Kill then remove the container default: false
client.images().list(options)
- Wait a Containeroptions
filters
- map[string][]string
to process on the images listclient.images().build(stream, options, registryAuth)
- Build an Image From a Dockerfileoptions
+registryAuth
username
password
serveraddress
client.images().create(options, registryAuth)
- Create Imageoptions
fromImage
fromSrc
repo
q
tag
registryAuth
username
password
serveraddress
client.images().inspect(name, options)
- Inspect an Imagename
- the name or id of the imageoptions
client.images().history(name, options)
- History of an Imagename
- the name or id of the imageoptions
client.images().push(name, options, registryAuth)
- Push an Image on the Registryname
- the name or id of the imageoptions
tag
registryAuth
username
password
serveraddress
client.images().tag(name, options)
- Tag an Imagename
- the name or id of the imageoptions
repo
tag
client.images().remove(name, options)
- Remove of Imagename
- the name or id of the imageoptions
repo
tag
client.images().search(options)
- Search Imagesname
- the name or id of the imageoptions
term
limit
filters
client.networks().list(options)
- List Networksoptions
filters
- JSON encoded network list filter.client.networks().create(model, options)
- Create a Networkmodel
- a json model representing the networkoptions
client.networks().inspect(id, options)
- Inspect a Networkid
- the network id or nameoptions
client.networks().remove(id, options)
- Remove a Networkid
- the network id or nameoptions
client.networks().connect(id, options)
- Connect a Container to a Networkid
- the network id or nameoptions
client.networks().disconnect(id, options)
- Disconnect a Container to a Networkid
- the network id or nameoptions
client.nodes().list(options)
- List Nodesid
- the node idoptions
filters
- JSON encoded node list filter.client.nodes().inspect(id, options)
- Inspect a Nodeid
- the node idoptions
client.nodes().remove(id, options)
- Remove a Nodeid
- the node idoptions
client.nodes().update(id, options)
- Update A Nodeid
- the node idoptions
version
- The version number of the node object being updated. This is required to avoid conflicting writes.client.plugins().list(options)
- List Pluginsoptions
filters
- a JSON encoded value of the filters (a map[string][]string) to process on the services list.client.plugins().install(options)
- Install a Pluginoptions
name
- Name of the plugin to pull. The name may include a tag or digest. This parameter is required.client.plugins().inspect(id, options)
- Inspect a Pluginoptions
client.plugins().enable(id, options)
- Enable a Pluginoptions
client.plugins().disable(id, options)
- Disable a Pluginoptions
client.plugins().remove(id, options)
- Remove a Pluginoptions
client.services().list(options)
- List Servicesoptions
filters
- a JSON encoded value of the filters (a map[string][]string) to process on the services list.client.services().create(options, registryAuth)
- Create a Serviceoptions
client.services().remove(id, options)
- Remove a Serviceid
- id or name of the serviceoptions
client.services().inspect(id, options)
- Inspect a Serviceid
- id or name of the serviceoptions
client.services().logs(id, options)
- Get Service Logsid
- id or name of the serviceoptions
details
- boolean, Show extra details provided to logs.follow
- boolean, Return the logs as a stream.stdout
- boolean, Return logs from stdoutstderr
- boolean, Return logs from stderrsince
- number, Only return logs since this time, as a UNIX timestamptimestamps
- boolean, Add timestamps to every log linetail
- Only return this number of log lines from the end of the logs. Specify as an integer or all to output all log lines.client.services().update(id, options, registryAuth)
- Update a Serviceid
- id or name of the serviceoptions
version
- The version number of the service object being updated. This is required to avoid conflicting writes.client.swarm().info(options)
- Swarm Infooptions
client.swarm().init(options)
- Initialize a Swarmoptions
client.swarm().join(options)
- Join a Swarmoptions
client.swarm().leave(options)
- Leave a Swarmoptions
force
- Boolean (false/true). Force leave swarm, even if this is the last manager or that it will break the cluster.client.swarm().update(options)
- Update a Swarmoptions
version
- The version number of the swarm object being updated. This is required to avoid conflicting writes.rotateWorkerToken
- Set to true to rotate the worker join token.rotateManagerToken
- Set to true to rotate the manager join token.client.tasks().list(options)
- List Servicesoptions
filters
- a JSON encoded value of the filters (a map[string][]string) to process on the tasks list.client.tasks().inspect(id, options)
- Inspect a Taskoptions
client.volumes().list(options)
- List Volumesoptions
filters
- a JSON encoded value of the filters (a map[string][]string) to process on the volumes list.client.volumes().create(options, registryAuth)
- Create a Volumeid
or name of the volumeoptions
client.volumes().remove(id, options)
- Remove a Volumeid
or name of the volumeoptions
client.volumes().inspect(id, options)
- Inspect a Volumeid
or name of the volumeoptions
client.info()
- System Wide Informationclient.auth(options)
- Authentication Configurationoptions
username
password
serveraddress
client.version()
- Versionclient.ping()
- Ping Daemonclient.events()
- Events Streamoptions
since
- Timestamp. Show all events created since timestamp and then streamuntil
- Timestamp. Show events created until given timestamp and stop streamingfilters
- value of the filters (a map[string][]string) to process on the event listFAQs
Harbor Master is a Docker Remote API client written in Node.js
The npm package harbor-master receives a total of 25 weekly downloads. As such, harbor-master popularity was classified as not popular.
We found that harbor-master demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.