authentik/.github/workflows/ci-web.yml

88 lines
2.1 KiB
YAML
Raw Normal View History

2021-08-30 19:21:15 +01:00
name: authentik-ci-web
on:
push:
branches:
- main
- next
- version-*
pull_request:
branches:
- main
2021-08-30 19:21:15 +01:00
jobs:
lint-eslint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3.3.0
2021-08-30 19:21:15 +01:00
with:
node-version: '16'
cache: 'npm'
cache-dependency-path: web/package-lock.json
- working-directory: web/
run: npm ci
2021-08-30 19:21:15 +01:00
- name: Generate API
run: make gen-client-web
2021-08-30 19:21:15 +01:00
- name: Eslint
working-directory: web/
run: npm run lint
2021-08-30 19:21:15 +01:00
lint-prettier:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3.3.0
2021-08-30 19:21:15 +01:00
with:
node-version: '16'
cache: 'npm'
cache-dependency-path: web/package-lock.json
- working-directory: web/
run: npm ci
2021-08-30 19:21:15 +01:00
- name: Generate API
run: make gen-client-web
2021-08-30 19:21:15 +01:00
- name: prettier
working-directory: web/
run: npm run prettier-check
2021-08-30 19:21:15 +01:00
lint-lit-analyse:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3.3.0
2021-08-30 19:21:15 +01:00
with:
node-version: '16'
cache: 'npm'
cache-dependency-path: web/package-lock.json
- working-directory: web/
run: npm ci
2021-08-30 19:21:15 +01:00
- name: Generate API
run: make gen-client-web
- name: lit-analyse
working-directory: web/
run: npm run lit-analyse
ci-web-mark:
2021-08-30 19:21:15 +01:00
needs:
- lint-eslint
- lint-prettier
- lint-lit-analyse
runs-on: ubuntu-latest
steps:
- run: echo mark
build:
needs:
- ci-web-mark
runs-on: ubuntu-latest
2021-08-30 19:21:15 +01:00
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3.3.0
2021-08-30 19:21:15 +01:00
with:
node-version: '16'
cache: 'npm'
cache-dependency-path: web/package-lock.json
- working-directory: web/
run: npm ci
2021-08-30 19:21:15 +01:00
- name: Generate API
run: make gen-client-web
2021-08-30 19:21:15 +01:00
- name: build
working-directory: web/
run: npm run build