Update upgrade process to support churchinfo 1.3.1 #711
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: Build, Test and Package | |
on: | |
pull_request: | |
branches: | |
- master | |
paths-ignore: | |
- '**/*.md' | |
push: | |
branches: | |
- master | |
paths-ignore: | |
- '**/*.md' | |
jobs: | |
test-n-package: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: ['20.x'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
# fetch full history so things like auto-changelog work properly | |
fetch-depth: 0 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
# setting a registry enables the NODE_AUTH_TOKEN env variable where we can set an npm token. REQUIRED | |
registry-url: 'https://registry.npmjs.org' | |
- name: Declare some variables | |
id: vars | |
shell: bash | |
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" | |
- name: get-npm-version | |
id: package-version | |
uses: martinbeentjes/npm-get-version-action@main | |
- name: Get Env Ready | |
run: | | |
npm ci | |
- name: Get Composer Cache Directory | |
id: composer-cache | |
run: | | |
cd src | |
echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- uses: actions/cache@v3 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} | |
restore-keys: | | |
${{ runner.os }}-composer- | |
- name: Build App | |
run: | | |
npm run package | |
- name: Run Docker | |
run: | | |
npm run ci-docker-test-start | |
docker-compose -f docker/docker-compose.test-php8-apache.yaml ps -a | |
docker-compose -f docker/docker-compose.test-php8-apache.yaml logs | |
- name: Test Server | |
run: | | |
curl -vvv http://127.0.0.1/api/public/echo | |
docker-compose -f docker/docker-compose.test-php8-apache.yaml ps -a | |
docker-compose -f docker/docker-compose.test-php8-apache.yaml logs | |
- name: Run Cypress Tests | |
run: | | |
npm run test | |
- name: Stop Docker | |
run: | | |
npm run ci-docker-test-down | |
- name: Upload zip file | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ChurchCRM-${{ steps.package-version.outputs.current-version}}-files | |
path: target/ChurchCRM-*.* |