Files
actions-environment/.gitea/workflows/deploy.yml
T

34 lines
750 B
YAML

name: Deployment
on:
push:
branches:
- main
- dev
jobs:
test:
environment: testing
runs-on: ubuntu-latest
steps:
- name: Get Code
uses: actions/checkout@v3
- name: Cache dependencies
uses: actions/cache@v3
with:
path: ~/.npm
key: npm-deps-${{ hashFiles('**/package-lock.json') }}
- name: Install dependencies
run: npm ci
- name: Run server
run: npm start & npx wait-on http://127.0.0.1:XYZ
- name: Run tests
run: npm test
- name: Output information
run: echo "..."
deploy:
needs: test
runs-on: ubuntu-latest
steps:
- name: Output information
run: |
echo "..."