← Files RivetARCHIVED FILE

node_modules/is-docker/readme.md

341 Bytes · Nov 5, 2026 · 12:09 UTC

↓ Download file

# is-docker

> Check if the process is running inside a Docker container

## Install

```
$ npm install is-docker
```

## Usage

```js
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.

SHA-256: 33bdcd155e57586ca2e3c2de12550f4a8451655af01a387ceea022698ee0a171