-
Notifications
You must be signed in to change notification settings - Fork 514
[TO_STAGE] Fix pip cache directory permission denied #6430
Conversation
For Python 2.7, a new version of PIP (7.1.0) attemps to write into .cache directory in gear's home directory which will cause permission denied error. Users do not have permission to create files or folders in gear's home directory. The .cache directory needs to be created during the installation process. As a result, a piece of code is added to "install" script to create .cache dir before pip install step happens to address the issue. Bug 1361755 Link https://bugzilla.redhat.com/show_bug.cgi?id=1361755 Signed-off-by: Vu Dinh <vdinh@redhat.com>
👍 I hope it will be merged soon |
[test] |
Added a python version bump from master. Also added the previous version to the compatible-version list ONLY for stage to avoid a gear migration. We'll need to come up with a script to run against PROD that creates the $GEAR_HOME/.cache directory for each existing python-2.7 cartridge with the correct selinux contexts and unix permission bits. |
Lets [test] again with the most recent change please. |
Evaluated for online test up to 0a76c19 |
Online Test Results: SUCCESS (https://ci.dev.openshift.redhat.com/jenkins/job/test_pull_requests_generic/764/) (Base Commit: 3218c23) |
Does this not work? https://developers.openshift.com/languages/python/getting-started.html#step3 |
@sferich888 it should work, thank you bro! I'll try it |
@sferich888 @raditv I don't understand what that blogpost is suggesting that differs from how we are already loading the virtual env. In a python 2.7 cartridge we use the below by default:
Its hard to read in the blogpost so maybe I'm reading incorrectly, but the blogpost suggests the exact same thing for python-2.7. The way it is loading the virtenv differently is suggested for python-3.3. |
I've confirmed with @sferich888 that no known workaround exists, we'll definitely need to get this change in. |
[merge] |
Evaluated for online merge up to 0a76c19 |
Online Merge Results: SUCCESS (https://ci.dev.openshift.redhat.com/jenkins/job/test_pull_requests_generic/778/) (Base Commit: f6a9e18) (Image: devenv-stage_1228) |
This should resolve issue #6390