Skip to content

Commit

Permalink
feat: Harden PyPI deployment via OIDC
Browse files Browse the repository at this point in the history
  • Loading branch information
alexpovel committed Apr 21, 2023
1 parent 3610828 commit 9fec4ed
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,11 @@ jobs:
needs: release-please
if: ${{ needs.release-please.outputs.created }}

# https://blog.pypi.org/posts/2023-04-20-introducing-trusted-publishers/
environment: pypi
permissions:
id-token: write

steps:
- uses: actions/checkout@v3

Expand All @@ -129,9 +134,6 @@ jobs:

- name: Publish package
uses: pypa/gh-action-pypi-publish@v1.8.4
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}

build-and-push-image:
name: Build Docker image and push to GitHub Container Registry
Expand Down

0 comments on commit 9fec4ed

Please sign in to comment.