Sign inSign up

nogil/python

By nogil

•Updated over 2 years ago

Image
2

4.4K

nogil/python repository overview

⁠Overview

This is a docker image of a modified version of Python 3.9 that supports running without the global interpreter lock (GIL). See https://github.com/colesbury/nogil⁠.

The images is based on Debian Bullseye.

⁠How to use this image

⁠Create a Dockerfile in your Python app project

FROM nogil/python

WORKDIR /usr/src/app

COPY requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt

COPY . .

CMD [ "python", "./your-daemon-or-script.py" ]

You can then build and run the Docker image:

$ docker build -t my-python-app .
$ docker run -it --rm --name my-running-app my-python-app

⁠Run a single Python script

For many simple, single file projects, you may find it inconvenient to write a complete Dockerfile. In such cases, you can run a Python script by using the Python Docker image directly:

$ docker run -it --rm --name my-running-script -v "$PWD":/usr/src/myapp -w /usr/src/myapp nogil/python python your-daemon-or-script.py

⁠License

View license information for Python 3⁠. This Readme is modified from the official Python image⁠ documentation under an MIT license⁠.

Tag summary

Content type

Image

Digest

sha256:993c328dc…

Size

337.5 MB

Last updated

over 2 years ago

docker pull nogil/python