Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/awibox/deploy-to-github-pages-action
:rocket: GitHub action that will help deploy your app to the repository for GitHub Pages
https://github.com/awibox/deploy-to-github-pages-action
deployment frontend github-action github-pages
Last synced: 2 months ago
JSON representation
:rocket: GitHub action that will help deploy your app to the repository for GitHub Pages
- Host: GitHub
- URL: https://github.com/awibox/deploy-to-github-pages-action
- Owner: awibox
- License: mit
- Created: 2020-01-19T08:40:51.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-09-13T07:34:24.000Z (over 1 year ago)
- Last Synced: 2024-03-14T20:04:46.190Z (10 months ago)
- Topics: deployment, frontend, github-action, github-pages
- Language: Shell
- Homepage:
- Size: 27.3 KB
- Stars: 13
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Deploy to GitHub pages
You can use GitHub Pages like hosting for your project.
To do this, you need to create a repository and activate GitHub Pages for the master branch and bind your domain.
Then use this action to help you set up automatic deployment from your app to your repository for GitHub Pages.## Getting started
Create a `deploy.yml` file in the workflows directory. You can use the example below:
```yaml
name: Deploy to GitHub Pages
on:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.2.0]
steps:
- uses: actions/checkout@v3
- name: install, build, and test
run: |
yarn install
yarn lint
yarn build
yarn test
env:
CI: true
- name: Deploy to production
uses: awibox/deploy-to-github-pages-action@master
env:
AUTHOR: awibox
BUILD_PATH: public
GITHUB_PAGE_NAME: awibox.github.io
PA_TOKEN: ${{ secrets.PA_TOKEN }}
USERNAME: awibox
EMAIL: [email protected]
```## Example repositories using this action
-
-
-## Environment variables
|Environment variable|Required|Description|Example|
|--------------------|--------|-----------|-------|
|`AUTHOR`|Required|Name of the repository owner|awibox|
|`BUILD_PATH`|Required|The directory where the static is built| public
|`GITHUB_PAGE_NAME`|Required|Name of the repository for GitHub Pages where the application will be collected|awibox.github.io|
|`PA_TOKEN`|Required|GitHub Private Access Token with editing rights for repo. You can create it using [GitHub Documentation](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens)|${{secrets.PA_TOKEN}}|
|`USERNAME`|Optional|The GitHub username for commits.|awibox|
|`EMAIL`|Optional|The email that is used for commits.|[email protected]|