Skip to content

Bump azure/webapps-deploy from 2 to 3 #158

Bump azure/webapps-deploy from 2 to 3

Bump azure/webapps-deploy from 2 to 3 #158

Workflow file for this run

name: 07-1. CI Workflow
# Trigger CI for every PR event, when PR has target branch = main
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
# The first job lints the code base
lint:
uses: githubabcs/gh-abcs-actions/.github/workflows/super-linter.yml@main
# CI job to run a test suite on the code base
ci:
name: CI
# We want to test across mutiple OSs, defined by our matrix
runs-on: ${{ matrix.os }}
needs: lint
strategy:
# Cancel all matrix jobs if one of them fails
fail-fast: true
matrix:
# our matrix for testing across node versions and OSs
node-version: [12, 14]
os: [windows-2019, ubuntu-20.04, ubuntu-22.04]
steps:
- name: Checkout
uses: actions/checkout@v4
# Configure our node environment according to matrix
- name: Setup node ${{ matrix.node-version }} on ${{ matrix.os }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Run test suite
run: |
echo npm ci
echo npm run build --if-present
echo npm test
# Add here the upload-artifact action
# If both linting and CI succeeds we want to deploy the code to a test environment
deploy-test:
name: Deploy to test env
runs-on: ubuntu-latest
needs: ci
environment:
name: TEST
url: https://test.company.com
steps:
- name: Checkout
uses: actions/checkout@v4
# Add here the download-artifact step
# Placeholder - this step would be some action or run commands that deploys the code
- name: Deploy to test env
if: ${{ success() }}
run: |
echo "Deploying to test environment"