-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
[Question] Is there a way to store private pypi credentials not in the Pipfile? #4644
Comments
@uranusjr How does the doc answers the question? I don't find any way to configure pipenv to get the password from the keyring, only a way to configure the password as env var, which is not what @ecs-jnguyen wanted (nor me). I've tried everything and can't find a way to configure pipenv similarly to pip on this topic.
Then, the password is configured with the command line Similarly, on pipenv, I configured:
But pipenv doesn't seem to query the keyring for the password and ends with:
On the server side, I see 2 401, both with only the username in the basic auth while it should have added the password for the second request. If I remove the myUser in the configuration, it's running indefinitely after receiving the first 401 (no Authorization header) and never triggers a second request. The solution using an env var is not what we expect as it needs some extra configuration that shouldn't be required. Is there something I missed? |
+1 it would be great to be able to provide repo credentials to a builder Docker container via Also, URL-encoding credentials is unusual and adds additional friction. If you have a central team managing your repo credentials & providing them as secret values to your CI/CD pipelines (Jenkins etc.), they are not typically going to URL-encode those first. So that means you're stuck having to add more logic into your build just to do that yourself (eg. in a shell script... gross). However, you most likely first had to figure out that was the problem in the first place: if you're unlucky enough to have those characters in your credentials, then you'd just get a mysterious access denied problem even though your credentials look fine. |
@rehevkor5 I have spent some time on this issue and have a PR out that you might find helpful: #5297 The problem though is you will still want to specify the credentials for the index as environment variables and reference them from the |
Would anyone be willing to test if this PR which is up to date with main and passing, which reads the |
pipenv==2023.2.18 has been released with support for reading the index information from the |
Hi @matteius. Thanks for your work, but I think it's not completely solving the problem. Also, note that your solution is copying the |
Hi I configured my pip.conf + keyring so that pip will use it to get the credentials before installing a package.
Is there a way to store my credentials on my local machine somewhere like how pip uses pip.conf? I would rather not store my credentials in my Pipfile since that will be checked into github. Also I don't want to set my credentials in the environment variables either since that would need to be configured in terminal and various IDE's.
$HOME/.config/pip/pip.conf
The text was updated successfully, but these errors were encountered: