-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,9 @@ on: | |
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
environment: publish | ||
permissions: | ||
id-token: write | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
sirosen
Author
Member
|
||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
@@ -19,5 +22,3 @@ jobs: | |
|
||
- name: Publish to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
password: ${{ secrets.PYPI_API_TOKEN }} |
@sirosen may I suggest that you spit this into two jobs? Security-wise, it's a bad idea to expose the OIDC token to the build process, as it can be poisoned on many levels.
We're still working on a PyPUG guide update with more concrete examples, but the basic idea is that you upload a GHA artifact in the build job and retrieve it in the first step of the publish job.