Skip to content

Build and deploy HTML on GitHub Actions #1669

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

Merged
merged 2 commits into from
Oct 23, 2020
Merged

Conversation

hugovk
Copy link
Member

@hugovk hugovk commented Oct 21, 2020

(Split from #1570.)

Adds a GitHub Actions workflow to build and deploy, like Travis CI.

Notes:

  • Travis CI builds against 3.7 and 3.7-dev. I only added 3.8 to GHA. Should it build against a range? For example, we can do 3.6-3.9.

  • It will only deploy for python/peps and master (like Travis)

  • I've left Travis CI in place for now. I'd suggest confirming the deploy works first from GHA, then removing from Travis in a followup PR.

  • (I also noticed that on Travis, it's deploying for both 3.7 and 3.7-dev. It probably only needs doing from a single job.)

  • Nice bonus: make -j$(nproc) is quicker on GHA (~80s) than Travis (~110s)

TODO

@pradyunsg
Copy link
Member

I'm guessing that @ewdurbin would know?

@brettcannon
Copy link
Member

I'm happy to take this if @ewdurbin can get us the secret necessary for the upload and what envvar to set it in.

@ewdurbin
Copy link
Member

Screen Shot 2020-10-21 at 4 14 56 PM

@pradyunsg
Copy link
Member

Awesome, so merging this should be enough to get stuff working? Yay!

@brettcannon
Copy link
Member

@pradyunsg not quite. While Ernest was nice enough to store the secrets, the workflow needs to be updated to actually set those values as environment variables.

@hugovk
Copy link
Member Author

hugovk commented Oct 22, 2020

Ah yes, updated!

Demo

I added some dummy values in my fork. With another branch, before setting env vars, fails to find credentials (as expected):

upload failed: build/peps.tar.gz to s3://pythondotorg-assets-staging/peps.tar.gz Unable to locate credentials

https://github.com/hugovk/peps/runs/1294073460?check_suite_focus=true#step:6:52

After adding env vars, found them (and dummy values didn't work, as expected):

upload failed: build/peps.tar.gz to s3://pythondotorg-assets-staging/peps.tar.gz An error occurred (InvalidAccessKeyId) when calling the PutObject operation: The AWS Access Key Id you provided does not exist in our records.

https://github.com/hugovk/peps/runs/1294144579?check_suite_focus=true#step:6:54

@brettcannon brettcannon merged commit 2f4ec80 into python:master Oct 23, 2020
@brettcannon
Copy link
Member

I just merged this and the first run worked! So I have gone ahead and removed the Travis webhook and configuration file.

Thanks, @hugovk

@hugovk hugovk deleted the gha-deploy branch October 23, 2020 18:43
@hugovk
Copy link
Member Author

hugovk commented Oct 23, 2020

Great, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants