Skip to content

Commit

Permalink
server workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
berlintay committed Aug 11, 2024
1 parent 2101a8f commit 9d869f4
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 48 deletions.
54 changes: 54 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: CI Workflow

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
lint_and_test:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set up node.js
uses: actions/setup-node@v4
with:
node-version: 20

- name: Install deps
run: npm install

- name: lint code
run: npm run lint
continue-on-error: true

- name: Run Test
run: npm test
continue-on-error: true

conditional_deploy:
needs: lint_and_test
runs-on: ubuntu-latest
if: ${{ success() }}
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Deploy
run: |
echo "Deploying KEAYSXYZ..."
manual_trigger:
runs-on: ubuntu-latest
needs: conditional_deploy
if: ${{ failure() }}
steps:
- name: Wait for manual re-run
uses: hmarr/auto-approve-action@v4
with:
github-token: ${{ secrets.GITHUB_TOKE }}
10 changes: 5 additions & 5 deletions .github/workflows/ss.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@ on:
branches:
- master
schedule:
- cron: '0 * * * *' # Runs every hour (optional)
- cron: ' 0 */3 * * *' # Runs every hour (optional)

jobs:
capture:
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '20'

Expand All @@ -28,10 +28,10 @@ jobs:
run: |
node capture-screenshot.js
env:
WEBSITE_URL: 'http://www.keays.xyz'
WEBSITE_URL: 'https://www.keays.xyz'

- name: Upload Screenshot
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: screenshot
path: media/screenshot.png
Expand Down
43 changes: 0 additions & 43 deletions .github/workflows/static.yml

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
770BF38C923493AD68CDFBE5466DE8ADB70273C312D7454518AFC689A6E23A91 comodoca.com 65be40fca244b

0 comments on commit 9d869f4

Please sign in to comment.