Deploy to 'main
' branch. (shouldn't need to be changed)
Important: Use the following in the bottom section of the GitHub Action.
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
publish_dir: ./public
https://github.com/marketplace/actions/github-pages-action
ssh-keygen -t rsa -b 4096 -C "$(git config user.email)" -f gh-pages -N ""
https://github.com/marketplace/actions/github-pages-action#%EF%B8%8F-create-ssh-deploy-key
cat gh-pages.pub
Copy the contents shown, normally (highlight and 'ctrl/command' + 'c' or right click and 'Copy'), and paste into GitHub 'Deploy Keys' under the Repository settings.
Name the Deploy Key: 'Public key of ACTIONS_DEPLOY_KEY
'
cat gh-pages
Copy the contents shown normally (highlight and 'ctrl/command' + 'c' or right click and 'Copy') and paste into GitHub 'Secrets' > 'Actions' under the Repository settings.
Name the Secret Action: 'ACTIONS_DEPLOY_KEY
'
Commit changes in code and push the site to Github. This will automatically kick off an GitHub Action process and will deploy the website/GitHub Pages site.