Skip to content

update knowledge

update knowledge #84

Workflow file for this run

name: Deploy and Audit
on:
push:
branches:
- master
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Set up Tailscale
uses: tailscale/github-action@v2
with:
oauth-client-id: ${{ secrets.TS_OAUTH_CLIENT_ID }}
oauth-secret: ${{ secrets.TS_OAUTH_SECRET }}
tags: tag:servers
- name: Execute deployment script
run: |
echo "Connecting to remote server..."
ssh -o StrictHostKeyChecking=no ubuntu@codenexis << 'EOF'
echo "Starting deployment..."
cd website
echo "Running deploy.sh..."
sudo su -c 'bash deploy.sh 2>&1 | tee -a /tmp/deployment_script.log'
echo "Deployment completed."
exit 0
EOF
audit:
runs-on: ubuntu-latest
needs: deploy
if: ${{ success() }}
steps:
- name: Checkout code
uses: actions/[email protected]
- name: Set up Node.js
uses: actions/[email protected]
with:
node-version: '22'
- name: Install dependencies
run: npm install discord.js node-fetch
- name: Run audit
env:
DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}
LIGHTHOUSE_API_KEY: ${{ secrets.LIGHTHOUSE_API_KEY }}
run: node ./utils/audit.js