291st/.github/workflows/Continues Integration.yaml
Zakary Timson 525f1e2762
Some checks failed
Continues Integration / Install dependencies (push) Successful in 35s
Continues Integration / Build (push) Successful in 53s
Continues Integration / Build production (push) Successful in 1m4s
Continues Integration / Build docker image (push) Failing after 47s
Update .github/workflows/Continues Integration.yaml
2023-07-28 17:42:20 +00:00

95 lines
2.2 KiB
YAML

name: Continues Integration
on: [push, workflow_dispatch]
jobs:
dependencies:
name: Install dependencies
container: git.zakscode.com/ztimson/runner
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Restore node_modules
uses: actions/cache/restore@v3
with:
path: ./node_modules
key: node_modules
restore-keys: node_modules
- name: Install dependencies
run: npm install
- name: Cache node_modules
uses: actions/cache@v3
with:
path: ./node_modules
key: node_modules
restore-keys: node_modules
build-dev:
name: Build
needs: dependencies
container: git.zakscode.com/ztimson/runner
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Restore node_modules
uses: actions/cache/restore@v3
with:
path: ./node_modules
key: node_modules
restore-keys: node_modules
- name: Build sources
run: npm run build:dev
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: build-dev
path: dist/
build-prod:
name: Build production
needs: dependencies
container: git.zakscode.com/ztimson/runner
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Restore node_modules
uses: actions/cache/restore@v3
with:
path: ./node_modules
key: node_modules
restore-keys: node_modules
- name: Build sources
run: npm run build:prod
- name: Upload artifacts
uses: actions/upload-artifact@v3
with:
name: build-prod
path: dist/
docker:
# needs: dependencies
name: Build docker image
container: git.zakscode.com/ztimson/runner
steps:
# - name: Checkout repository
# uses: actions/checkout@v3
- uses: ztimson/actions/docker@develop
with:
image: ztimson/test
registry: git.zakscode.com
registry_user: ztimson
registry_pass: ${{secrets.deploy_token}}