Add permissions, fix artifact name, filter branches
This commit is contained in:
parent
1c824da32b
commit
f67eb328bf
2 changed files with 7 additions and 1 deletions
2
.github/workflows/netlify-main.yaml
vendored
2
.github/workflows/netlify-main.yaml
vendored
|
@ -4,6 +4,8 @@ on:
|
|||
workflows: ["Build"]
|
||||
types:
|
||||
- completed
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
|
|
6
.github/workflows/netlify-pr.yaml
vendored
6
.github/workflows/netlify-pr.yaml
vendored
|
@ -4,10 +4,14 @@ on:
|
|||
workflows: ["Build"]
|
||||
types:
|
||||
- completed
|
||||
branches-ignore:
|
||||
- main
|
||||
jobs:
|
||||
deploy:
|
||||
if: github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.event == 'pull_request'
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
deployments: write
|
||||
environment: Netlify
|
||||
steps:
|
||||
- name: 📝 Create Deployment
|
||||
|
@ -34,7 +38,7 @@ jobs:
|
|||
uses: dawidd6/action-download-artifact@v2
|
||||
with:
|
||||
run_id: ${{ github.event.workflow_run.id }}
|
||||
name: previewbuild
|
||||
name: build
|
||||
path: webapp
|
||||
|
||||
- name: Add redirects file
|
||||
|
|
Loading…
Reference in a new issue