Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Control where virtualenv is created #1385

Closed
caliph007 opened this issue Feb 1, 2018 · 1 comment
Closed

Control where virtualenv is created #1385

caliph007 opened this issue Feb 1, 2018 · 1 comment

Comments

@caliph007
Copy link

For deploying in production it would be really helpful to have tighter control on the location where the virtual env gets created.

Just fyi a transscript from my last deploy:

[server.com] run: export PIPENV_VENV_IN_PROJECT=true
[server.com] run: pipenv --three
[server.com] out: Creating a virtualenv for this project…
[server.com] out: Using /usr/bin/python3 to create virtualenv…
[server.com] out: ⠋Running virtualenv with interpreter /usr/bin/python3
[server.com] out: Using base prefix '/usr'
[server.com] out: New python executable in /home/ubuntu/.local/share/virtualenvs/application-qO5bWt8a/bin/python3
[server.com] out: Also creating executable in /home/ubuntu/.local/share/virtualenvs/application-qO5bWt8a/bin/python
[server.com] out: Installing setuptools, pkg_resources, pip, wheel...done.
[server.com] out:
[server.com] out: Virtualenv location: /home/ubuntu/.local/share/virtualenvs/application-qO5bWt8a

Why is pipenv disrespecting the environment variable PIPENV_VENV_IN_PROJECT ?

@techalchemy
Copy link
Member

@caliph007 if you are using docker you will need to use proper docker commands to build your environment, as export will not accomplish this. In addition you will also need to pass WORKDIR. See this link for more information or our example Dockerfile for a slightly different example. Beyond that, if you are still having issues we will need your dockerfile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants