Installations
npm install dockerode-compose
Developer
apocas
Developer Guide
Module System
CommonJS
Min. Node Version
Typescript Support
No
Node Version
18.7.0
NPM Version
8.15.0
Statistics
145 Stars
126 Commits
31 Forks
10 Watching
1 Branches
10 Contributors
Updated on 25 Nov 2024
Bundle Size
120.93 kB
Minified
37.12 kB
Minified + Gzipped
Languages
JavaScript (98.75%)
Dockerfile (1.25%)
Total Downloads
Cumulative downloads
Total Downloads
75,745
Last day
-11.4%
233
Compared to previous day
Last week
-22.4%
1,161
Compared to previous week
Last month
10.1%
5,380
Compared to previous month
Last year
161.1%
44,231
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
dockerode-compose
docker-compose
in Node.js using dockerode.
Everything is executed programmatically using dockerode
, consequently Docker's API.
ToDo:
- Finish compose spec
- User friendly functions (partial deploys, etc) needs to be implemented.
Installation
npm install dockerode-compose
Getting started
To use dockerode-compose
first you need to instantiate it:
1var Dockerode = require('dockerode'); 2var DockerodeCompose = require('dockerode-compose'); 3 4var docker = new Dockerode(); 5var compose = new DockerodeCompose(docker, './test/wordpress.yml', 'wordpress'); 6 7(async () => { 8 await compose.pull(); 9 var state = await compose.up(); 10 console.log(state); 11})();
Documentation
- new DockerodeCompose(dockerode, file, project_name)
- compose.up()
- compose.pull(service, options) - omit service to pull all images, options.streams return the streams without waiting, options.verbose pipe the streams to stdout.
Tests
- Tests are implemented using
mocha
andchai
. Run them withnpm test
.
Examples
Check the examples folder for more specific use cases examples.
License
Pedro Dias - @pedromdias
Licensed under the Apache license, version 2.0 (the "license"); You may not use this file except in compliance with the license. You may obtain a copy of the license at:
http://www.apache.org/licenses/LICENSE-2.0.html
Unless required by applicable law or agreed to in writing, software distributed under the license is distributed on an "as is" basis, without warranties or conditions of any kind, either express or implied. See the license for the specific language governing permissions and limitations under the license.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0
Reason
1 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
Reason
Found 7/18 approved changesets -- score normalized to 3
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/node.js.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'main'
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/node.js.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/apocas/dockerode-compose/node.js.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/node.js.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/apocas/dockerode-compose/node.js.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/node.js.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/apocas/dockerode-compose/node.js.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/node.js.yml:45: update your workflow using https://app.stepsecurity.io/secureworkflow/apocas/dockerode-compose/node.js.yml/main?enable=pin
- Warn: containerImage not pinned by hash: test/assets/complex_example/2-nodejs-projects/simple-node-app-1235/Dockerfile:1: pin your Docker image by updating ubuntu to ubuntu@sha256:278628f08d4979fb9af9ead44277dbc9c92c2465922310916ad0c46ec9999295
- Warn: containerImage not pinned by hash: test/assets/complex_example/2-nodejs-projects/simple-node-app-1235/simple-node-app-1236/Dockerfile:1: pin your Docker image by updating ubuntu to ubuntu@sha256:278628f08d4979fb9af9ead44277dbc9c92c2465922310916ad0c46ec9999295
- Warn: containerImage not pinned by hash: test/assets/complex_example/2-nodejs-projects/simple-node-app/Dockerfile:1: pin your Docker image by updating ubuntu to ubuntu@sha256:278628f08d4979fb9af9ead44277dbc9c92c2465922310916ad0c46ec9999295
- Warn: containerImage not pinned by hash: test/assets/test_build/backend.Dockerfile:1: pin your Docker image by updating ubuntu to ubuntu@sha256:278628f08d4979fb9af9ead44277dbc9c92c2465922310916ad0c46ec9999295
- Warn: containerImage not pinned by hash: test/assets/test_build/backend/Dockerfile:1: pin your Docker image by updating ubuntu to ubuntu@sha256:278628f08d4979fb9af9ead44277dbc9c92c2465922310916ad0c46ec9999295
- Warn: containerImage not pinned by hash: test/assets/test_build/build_things/Dockerfile:1: pin your Docker image by updating ubuntu to ubuntu@sha256:278628f08d4979fb9af9ead44277dbc9c92c2465922310916ad0c46ec9999295
- Warn: npmCommand not pinned by hash: .github/workflows/node.js.yml:36
- Info: 0 out of 3 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 1 third-party GitHubAction dependencies pinned
- Info: 0 out of 6 containerImage dependencies pinned
- Info: 0 out of 1 npmCommand dependencies pinned
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 19 are checked with a SAST tool
Score
3.6
/10
Last Scanned on 2024-11-25
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More