Skip to content

Merge pull request #72 from 0xLaurens/dependabot/npm_and_yarn/mongodb… #91

Merge pull request #72 from 0xLaurens/dependabot/npm_and_yarn/mongodb…

Merge pull request #72 from 0xLaurens/dependabot/npm_and_yarn/mongodb… #91

Workflow file for this run

# .github/workflows/netlify.yml
name: Build and Deploy to Netlify
on:
push:
branches:
- main
jobs:
build-artifacts:
name: "Build Artifacts"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: npm install and build the Triplo website
run: |
npm install --legacy-peer-deps
npm run build --production
- uses: actions/upload-artifact@v3
with:
name: Triplo
path: './dist/apps/triplo'
run-tests:
name: "Run Tests"
runs-on: ubuntu-latest
needs: build-artifacts
steps:
- uses: actions/checkout@v3
- name: npm install and run test
run: |
npm install --legacy-peer-deps
npm run test
deploy-to-netlify:
name: "Deploy to Netlify"
runs-on: ubuntu-latest
needs: run-tests
steps:
- uses: actions/checkout@v3
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: Triplo
path: './dist/apps/triplo'
- name: Deploy to Netlify
uses: nwtgck/[email protected]
with:
publish-dir: './dist/apps/triplo'
production-branch: main
enable-commit-comment: true
env:
NETLIFY_AUTH_TOKEN: ${{ secrets.NETLIFY_AUTH_TOKEN }}
NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }}
timeout-minutes: 1