build: update auth in sign+deploy scripts #5081
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Follow-up of #5077
As said, I don't have the password for the signing key, so I can't actually test the changes to the gpg decryption command. That's just a trivial change though, and it reads the passphrase from stdin now, which is the preferred way. Just take a look at the manual.
https://man.archlinux.org/man/gpg.1#passphrase-fd
I've messaged @beardypig and asked him to post the password to the protonmail account, as a backup.
The second change is in regards to the PyPI deploy script.
The current authentication method when uploading release files to PyPI is password based. This will change it to a token-based authentication, with different env vars. I will add those to the secret env vars after this has been merged. The token has been sent to the protonmail mailbox.
https://twine.readthedocs.io/en/latest/index.html#configuration
I've also removed inactive collaborators from the PyPI package and made 2FA a requirement. Since the streamlink account doesn't have 2FA enabled, this account is now unable to make modifications to the package. This shouldn't affect the upload token, I hope.
https://pypi.org/help/#apitoken
There's a slight chance that these changes will cause issues with the next release, so we'll have to see.