Files
bot-whatsapp/.github/workflows/netlify.yml
Leifer Mendez 96b569766c docs: 🔥 added netlify
2022-12-28 20:58:17 +01:00

50 lines
1.5 KiB
YAML

# .github/workflows/netlify.yml
name: Build and Deploy to Documentation Netlify
on:
pull_request:
branches:
- dev
- main
types: [closed]
jobs:
############ BUILD PACKAGE ############
build-package:
name: Build Package
runs-on: ubuntu-latest
needs:
- test-unit
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: 16.x
cache: 'yarn'
registry-url: https://registry.npmjs.org/
- run: corepack enable
- name: Install NPM Dependencies
run: yarn install --immutable --network-timeout 300000
- name: Build Package
run: cd ./packages/docs/ && npm run build
- uses: actions/checkout@v2
- name: Deploy to Netlify
uses: nwtgck/actions-netlify@v1.2
with:
publish-dir: './packages/docs/dist'
github-token: ${{ secrets.GITHUB_TOKEN }}
deploy-message: 'Deploy from GitHub Actions'
enable-pull-request-comment: false
enable-commit-comment: true
overwrites-pull-request-comment: true
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
timeout-minutes: 1