mirror of
https://github.com/modelec/modelec.club.git
synced 2026-01-18 16:37:30 +01:00
Add codeql and dry run CI/CD
This commit is contained in:
4
.github/codeql/codeql-analysis.yml
vendored
Normal file
4
.github/codeql/codeql-analysis.yml
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
name: "Default setup"
|
||||
queries:
|
||||
- javascript-security-and-quality.qls
|
||||
- typescript-security-and-quality.qls
|
||||
4
.github/codeql/codeql-config.yml
vendored
Normal file
4
.github/codeql/codeql-config.yml
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
name: "Default setup"
|
||||
queries:
|
||||
- javascript-security-and-quality.qls
|
||||
- typescript-security-and-quality.qls
|
||||
39
.github/workflows/deploy-test.yml
vendored
Normal file
39
.github/workflows/deploy-test.yml
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
name: Deploy to server
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
|
||||
jobs:
|
||||
build-and-deploy:
|
||||
runs-on: ubuntu-latest
|
||||
environment: recette
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20'
|
||||
|
||||
- name: Install dependencies and build
|
||||
run: |
|
||||
npm ci
|
||||
npm run build
|
||||
|
||||
- name: Copy build directory to server
|
||||
uses: Dylan700/sftp-upload-action@v1.2.3
|
||||
with:
|
||||
server: ${{ secrets.SERVER_HOST }}
|
||||
username: ${{ secrets.SERVER_USERNAME }}
|
||||
password: ${{ secrets.SERVER_PASSWORD }}
|
||||
port: ${{ secrets.SERVER_PORT }}
|
||||
uploads: |
|
||||
./dist => /var/www/modelec.club
|
||||
dry-run: true
|
||||
delete: true
|
||||
1
.github/workflows/deploy.yml
vendored
1
.github/workflows/deploy.yml
vendored
@@ -35,3 +35,4 @@ jobs:
|
||||
port: ${{ secrets.SERVER_PORT }}
|
||||
uploads: |
|
||||
./dist => /var/www/modelec.club
|
||||
delete: true
|
||||
Reference in New Issue
Block a user