time-to-botec/squiggle/node_modules/is-docker
NunoSempere b6addc7f05 feat: add the node modules
Necessary in order to clearly see the squiggle hotwiring.
2022-12-03 12:44:49 +00:00
..
cli.js feat: add the node modules 2022-12-03 12:44:49 +00:00
index.d.ts feat: add the node modules 2022-12-03 12:44:49 +00:00
index.js feat: add the node modules 2022-12-03 12:44:49 +00:00
license feat: add the node modules 2022-12-03 12:44:49 +00:00
package.json feat: add the node modules 2022-12-03 12:44:49 +00:00
readme.md feat: add the node modules 2022-12-03 12:44:49 +00:00

is-docker

Check if the process is running inside a Docker container

Install

$ npm install is-docker

Usage

const isDocker = require('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.