Update Authentication + Build Script

This commit is contained in:
Moritz Utcke
2023-05-18 14:01:54 +04:00
parent 5559f5ca4d
commit 492b790527
22 changed files with 276 additions and 163 deletions

View File

@@ -3,8 +3,6 @@ name: Node.js CD
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
@@ -19,9 +17,10 @@ jobs:
password: "!2Zc727cI1"
port: 22
script: |
cd /home/root/apps/online-energieausweis
cd ~/apps/online-energiausweis
git reset --hard HEAD
git clean -f -d
git pull origin main
git status
pnpm install --prod
pnpm run build
pm2 restart online-energieausweis
pnpm install
bash build.sh

View File

@@ -1,24 +0,0 @@
# This workflow will do a clean install of node dependencies,
# build the source code and run tests across different versions of node
# For more information see:
# https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: Node.js CI
on:
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 12
uses: actions/setup-node@v2
with:
node-version: 19.x
- run: npm i
- run: npm run build --if-present
- run: npm test

View File

@@ -1,18 +0,0 @@
name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: docker build . --file Dockerfile --tag online-energieausweis:$(date +%s)