is-docker

3.0.0last stable release 4 years ago
Complexity Score
Low
Open Issues
1
Dependent Projects
639
Weekly Downloadsglobal
39,314,024

License

  • MIT
    • Yesattribution
    • Permissivelinking
    • Permissivedistribution
    • Permissivemodification
    • Nopatent grant
    • Yesprivate use
    • Permissivesublicensing
    • Notrademark grant

Downloads

Readme

is-docker

Check if the process is running inside a Docker container

Install

npm install is-docker

Usage

import isDocker from 'is-docker';

if (isDocker()) {
    console.log('Running inside a Docker container');
}

CLI

is-docker

Exits with code 0 if inside a Docker container and 2 if not.

Related

  • is-inside-container - Check if the process is running inside a container

Dependencies

No runtime dependency information found for this package.

CVE IssuesActive
0
Scorecards Score
4.20
Test Coverage
No Data
Follows Semver
Yes
Github Stars
218
Dependenciestotal
4
DependenciesOutdated
4
DependenciesDeprecated
0
Threat Modelling
No
Repo Audits
No

Learn how to distribute is-docker in your own private NPM registry

npm config set registry  https://npm.cloudsmith.com/owner/repo
Processing...
Done
npm install is-docker
Processing...
Done

9 Releases

NPM on Cloudsmith

Getting started with NPM on Cloudsmith is fast and easy.