$ gnpm install is-inside-container
Check if the process is running inside a container
npm install is-inside-container
import isInsideContainer from 'is-inside-container';
if (isInsideContainer()) {
console.log('Running inside a container');
}
is-inside-container
Exits with code 0 if inside a container and 2 if not.
Copyright 2013 - present © cnpmjs.org | Home |