Skip to main content

A small Python utility that tries to check if we are inside a Docker container.

Project description

docker-check

A small Python utility that tries to check if we are inside a Docker container.

Installation

pip install -e git+https://github.com/night-crawler/docker-check.git@HEAD#egg=docker-check
# OR
pip install docker-check

Sample

from docker_check import checker
checker.has_dockerenv()
checker.has_docker_in_proc_1_cgroup()
checker.is_inside_container()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

docker_check-0.0.2.tar.gz (1.8 kB view hashes)

Uploaded source

Built Distribution

docker_check-0.0.2-py3-none-any.whl (3.8 kB view hashes)

Uploaded 3 6

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page