
Security News
The Hidden Blast Radius of the Axios Compromise
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.
Use docker functions in your javascript code
$ npm install dockercmd
var dockercmd = require( 'dockercmd' );
dockercmd.ps().then(result => {
console.log(result);
});
Return exemple :
[
{
"id":"a5d55b5c3ebe",
"port":"",
"image":"hello-world",
"created":"2017-07-24 11:56:50 +0200 CEST",
"status":"Exited (0) About an hour ago"
},
{
"id":"734121f89a41",
"port":"",
"image":"postgres:9.6-alpine",
"created":"2017-07-19 16:29:23 +0200 CEST",
"status":"Exited (0) About an hour ago"
}
]
dockercmd.images().then(result => {
console.log(result);
});
Return exemple :
[
{
"id":"f6a9a3968e52",
"repository":"postgres",
"tag":"9.6-alpine",
"size":"37.7 MB",
"created":"2017-07-15 00:58:03 +0200 CEST"
},
{
"id":"1815c82652c0",
"repository":"hello-world",
"tag":"latest",
"size":"1.84 kB",
"created":"2017-06-14 21:29:01 +0200 CEST"
}{
"id":"8a0824e0a178",
"repository":"docker.elastic.co/elasticsearch/elasticsearch",
"tag":"5.4.1",
"size":"519 MB",
"created":"2017-06-01 16:43:22 +0200 CEST"
}
]
dockercmd.stats(container_id).then(result => {
console.log(result);
});
Return exemple :
{
"container_id":"734121f89a41",
"cpu_perc":"0.04%",
"mem_usage":{
"used":"12.15 MiB",
"limit":"15.56 GiB"
},
"mem_perc":"0.08%",
"net_io":{
"in":"0 B",
"out":"0 B"
},
"block_io":{
"in":"0 B",
"out":"90.1 kB"
}
}
dockercmd.start(container_id).then(result => {
console.log(result);
});
dockercmd.stop(container_id).then(result => {
console.log(result);
});
dockercmd.rm(container_id).then(result => {
console.log(result);
});
dockercmd.rmi(image_id).then(result => {
console.log(result);
});
FAQs
Use docker functions in your javascript code
We found that dockercmd demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.