Added DISABLE_ESLINT_PLUGIN to allow build #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to Contentful | |
on: | |
push: | |
tags: | |
- 'v[0-9]+.[0-9]+.[0-9]' | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [20.x] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
registry-url: https://npm.pkg.github.com | |
- name: Cache npm packages | |
id: cache-packages | |
uses: actions/cache@v4 | |
with: | |
path: node_modules | |
key: ${{ runner.OS }}-npm-${{ hashFiles('**/package-lock.json') }} | |
- name: Install dependencies | |
if: steps.cache-packages.outputs.cache-hit != 'true' | |
run: npm install --omit=dev | |
env: | |
NODE_AUTH_TOKEN: ${{ github.token }} | |
- name: Build deployable code | |
run: npm run build | |
- uses: contentful/actions-app-deploy@v1 | |
name: Deploy to Contentful | |
with: | |
organization-id: ${{ secrets.CONTENTFUL_ORG_ID }} | |
app-definition-id: ${{ secrets.CONTENTFUL_APP_DEF_ID }} | |
access-token: ${{ secrets.CONTENTFUL_ACCESS_TOKEN }} | |
folder: build |