Automatically retrieve credentials for AWS CodeArtifact.
Project description
AWS CodeArtifact Keyring Backend
The keyrings.codeartifact
package provides authentication for publishing and consuming packages within a private
PyPi repository hosted on AWS CodeArtifact; it contains an extension to the
keyring library that will automatically inject a time-limited access token.
Installation
To install this package, install the "keyrings.codeartifact" package using pip
:
pip install keyrings.codeartifact
Usage
The keyring
library has been integrated with recent versions of pip and twine. Once installed, this library will
automatically supply credentials whenever pip/twine (or other keyring-enabled package) attempts to use a repository
hosted within CodeArtifact. It will use any appropriate AWS credentials provided in ~/.aws/credentials
by default.
--index-url https://${DOMAIN}-${ACCOUNT}.d.codeartifact.${REGION}.amazonaws.com/pypi/${REPOSITORY}/simple/
Config
This backend provides a number of configuration options to modify the behaviour of the AWS client.
These configuration options can be specified within a [codeartifact]
section of the keyringrc.cfg
.
Run keyring diagnose
to find its as the location; it varies between different platforms.
Options
aws_access_key_id
Specifies the key ID used to authenticate with AWS.aws_secret_access_key
Specifies the secret key used to authenticate with AWS.profile_name
Specifies the name of a specific profile to use with the AWS client.
For more explanation of these options see the AWS CLI documentation.
Example:
[codeartifact]
profile_name=profile_name
aws_access_key_id=xxxxxxxxx
aws_secret_access_key=xxxxxxxxx
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for keyrings.codeartifact-1.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | f18c70f257a3cc80fe7d34044f27f8ba8e50c02a5dbba713d694886787561e49 |
|
MD5 | eeb3e52b395a040cbe0bbc808d905932 |
|
BLAKE2b-256 | 0f0514f088510a05e60a61468a45365ff06e792a8133c3cfe3f7db106073edc4 |
Hashes for keyrings.codeartifact-1.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e85b1231ce16a88e671c250271561907ff8072a08be8e51c493ed272c183cc5c |
|
MD5 | b51702bae7008f0bd0fff0589a539ad3 |
|
BLAKE2b-256 | 42c3d24ecb2056da974f41ceb4a7dcb1135cd111690b0a226c0ccebcd1a56405 |