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

Automate Package Publishing to PyPI and Test PyPI Using GitHub Actions and API Tokens #13

Closed
Fovty opened this issue May 16, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request feature

Comments

@Fovty
Copy link
Member

Fovty commented May 16, 2024

Issue

Automate Package Publishing to PyPI and Test PyPI Using GitHub Actions and API Tokens

Problem to solve

Currently, the process for publishing packages to PyPI and Test PyPI involves manually setting environment variables for authentication. This can be error-prone and less secure. We need to automate the process in our GitHub Actions workflow using API tokens for secure and efficient package uploads.

Further details

  • Affects the build and deployment process of Python packages.
  • We will utilize the GitHub Secrets feature to securely store and access the API tokens.
  • This change will streamline the deployment process, reducing the chance of human error and improving security by avoiding direct password usage.

Proposal

  1. Generate API Tokens:

    • Generate API tokens for both PyPI and Test PyPI.
    • Add these tokens as secrets in the GitHub repository.
  2. Update GitHub Actions Workflow:

    • Modify the existing build-publish-package.yaml to use the stored API tokens for authentication.
    • Ensure the workflow handles both Test PyPI and PyPI uploads.

Who can address the issue

This issue can be addressed by a developer with experience in:

  • GitHub Actions workflows
  • Python package management with Poetry and Twine
  • Secure management of credentials using GitHub Secrets

Other links/references

@Fovty Fovty self-assigned this May 16, 2024
@Fovty Fovty added enhancement New feature or request feature labels May 16, 2024
@Fovty Fovty closed this as completed May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request feature
Projects
None yet
Development

No branches or pull requests

1 participant