<commit_before># google/python-runtime

[`google/python-runtime`](https://index.docker.io/u/google/python-runtime) is a [docker](https://docker.io) base image for easily running [Python](http://python.org) application.

It can automatically bundle a python application with its dependencies and set the default entrypoint with no additional Dockerfile instructions.

It is based on [`google/python`](https://index.docker.io/u/google/python) base image.

## Usage

- Create a Dockerfile in your python application directory with the following content:

        FROM google/python-runtime

- Run the following command in your application directory:

        docker build -t app .

## Sample
  
See the [sources](/hello) for [`google/python-hello`](https://index.docker.io/u/google/python-hello) based on this image.

## Notes

The image assumes that your application:

- has a [`requirements.txt`](https://pip.pypa.io/en/latest/user_guide.html#requirements-files) file to specify its dependencies
- listens on port `8080`
- either has a `main.py` script as entrypoint or defines `ENTRYPOINT ["/env/bin/python", "/app/some_other_file.py"]` in its `Dockerfile`

When building your application docker image, `ONBUILD` triggers:

- Create a new virtualenv under the `/env` directory in the container
- Fetch the dependencies listed in `requirements.txt` into the virtualenv using `pip install` and cache them appropriatly.
- Copy the application sources under the `/app` directory in the container
<commit_msg>runtime/README: better wording<commit_after># google/python-runtime

[`google/python-runtime`](https://index.docker.io/u/google/python-runtime) is a [docker](https://docker.io) base image that makes it easy to dockerize standard [Python](http://python.org) application.

It can automatically bundle a Python application and its dependencies with a single line Dockerfile.

It is based on [`google/python`](https://index.docker.io/u/google/python) base image.

## Usage

- Create a Dockerfile in your python application directory with the following content:

        FROM google/python-runtime

- Run the following command in your application directory:

        docker build -t app .

## Sample
  
See the [sources](/hello) for [`google/python-hello`](https://index.docker.io/u/google/python-hello) based on this image.

## Notes

The image assumes that your application:

- has a [`requirements.txt`](https://pip.pypa.io/en/latest/user_guide.html#requirements-files) file to specify its dependencies
- listens on port `8080`
- either has a `main.py` script as entrypoint or defines `ENTRYPOINT ["/env/bin/python", "/app/some_other_file.py"]` in its `Dockerfile`

When building your application docker image, `ONBUILD` triggers:

- Create a new virtualenv under the `/env` directory in the container
- Fetch the dependencies listed in `requirements.txt` into the virtualenv using `pip install` and leverage docker caching appropriately
- Copy the application sources under the `/app` directory in the container

{'fraction_non_alphanumeric': 0.1044776119402985, 'fraction_numerical': 0.0026533996683250414, 'mean_word_length': 4.434234234234234, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 10, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7345617', 'n_tokens_mistral': 861, 'n_tokens_neox': 815, 'n_words': 316}