This project is no longer actively maintained.
Back in 2017, few open source project provide docker image, etc and our jobs had a real nice goal. Now (2023), all open source community is mature, provides tools and images more than we needs. Thanks to all members for their time and effort.
A docker container to run poetry
- Having Docker and docker-compose installed (=> https://docs.docker.com/install/ & https://docs.docker.com/compose/install/)
- Having a Sonarqube server and a project to analyze
Just clone the repo with the usual : git clone https://github.com/airdock-io/docker-python-poetry.git
- Enter the repo
- Type
make build
to build the image locally - If you want to see other commands available
make help
Be aware that, before it will execute your command it will execute a poetry install
to make sure that a venv is created and that command will be executed properly.
See https://python-poetry.org/ for more informations on configration
Then to use the image locally: docker run --rm -v ${PWD}:/app python-poetry:latest
Or to use the image from docker hub: docker run --rm -v ${PWD}:/app airdock/python-poetry:latest
Some of these vars are defined in the Dockerfile and others are not. Vars used by the entrypoint and command should be defined in dockerfile, vars relative to the command are defined (if not in compose environment section) in entrypoint with a default value.
Var | Default Value |
---|---|
HOME | /usr/local/lib |
Every scripts located (or mounted) in the /docker-entrypoint-init.d
folder and ending with sh will be executed at startup before the command.