Use artifact to share website dir between jobs #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Example of publishing a private website | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
prepare: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Prepend timestamp to index.html | |
run: | | |
echo "Published at: $(date)<br/>" | cat - ./public/index.html > temp && mv temp ./public/index.html | |
- name: Create website artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: website | |
path: ./public | |
publish: | |
needs: prepare | |
uses: probcomp/gen-website-private/.github/workflows/publish_private_website.yml@main | |
with: | |
artifact: website | |