Poetry: Option to disable use of a virtual env

Created on 16 May 2018  路  5Comments  路  Source: python-poetry/poetry

Inside docker deployments it is nice to not have to use a virtual env at all. Is there an option to disable using one when installing from lock?

Most helpful comment

In current version this should be:

poetry config virtualenvs.create false

All 5 comments

You can disable the creation of virtualenvs completely by setting a config option to False:

poetry config settings.virtualenvs.create false

Note that this is a global option and that I did not test it inside a docker container.

That worked great. Sorry I must鈥檝e missed that in the docs.

@mackeyja92 No, you didn't miss anything. The possible configuration settings, except those related to repositories, are not documented yet.

this didn't work for me in 1.0.0b1:

(title_detector) MacBook-MacBook-Pro-de-Marc:title_detector marctorrellassocastro$ poetry config settings.virtualenvs.create false

[FileNotFoundError]
[Errno 2] No such file or directory: '/Users/marctorrellassocastro/Library/Application Support/pypoetry/config.toml'

In current version this should be:

poetry config virtualenvs.create false
Was this page helpful?
0 / 5 - 0 ratings