codeql-action/node_modules/is-inside-container
github-actions[bot] 40a500c743 Update checked-in dependencies 2023-07-13 09:09:17 +00:00
..
cli.js Update checked-in dependencies 2023-07-13 09:09:17 +00:00
index.d.ts Update checked-in dependencies 2023-07-13 09:09:17 +00:00
index.js Update checked-in dependencies 2023-07-13 09:09:17 +00:00
license Update checked-in dependencies 2023-07-13 09:09:17 +00:00
package.json Update checked-in dependencies 2023-07-13 09:09:17 +00:00
readme.md Update checked-in dependencies 2023-07-13 09:09:17 +00:00

readme.md

is-inside-container

Check if the process is running inside a container

Install

npm install is-inside-container

Usage

import isInsideContainer from 'is-inside-container';

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

CLI

is-inside-container

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

Supported containers

  • Docker
  • Podman
  • is-docker - Check if the process is running inside a Docker container