Skip to content

Update README.md

Update README.md #66

Workflow file for this run

name: Build and Deploy
on:
push:
branches:
- main
permissions:
contents: write
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout Source Repository
uses: actions/checkout@v2
- name: Cache NPM dependencies
uses: actions/cache@v2
with:
path: ~/.npm
key: npm-${{ hashFiles('**/*.lock') }}
restore-keys: |
npm-
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '20'
- name: Install Dependencies
run: npm install
- name: Build
run: npm run build
- name: Create Zip Archive
run: |
cd dist
zip -r ../FRM-WebUI.zip .
- name: Deploy to FicsitRemoteMonitoring Repository
uses: actions/upload-artifact@v2
with:
name: FRM-WebUI
path: FRM-WebUI.zip
- name: Checkout Target Repository
uses: actions/checkout@v2
with:
repository: V0ID-Whisperer/FicsitRemoteMonitoring
- name: Download Zip File
uses: actions/download-artifact@v2
with:
name: FRM-WebUI
- name: Unzip Contents
run: |
unzip FRM-WebUI.zip -d tmp
rm FRM-WebUI.zip
- name: Replace www Folder Contents
run: |
rm -rf ./www/*
mv ./tmp/* www
rm -rf ./tmp
- name: Set up SSH
run: |
mkdir -p ~/.ssh
echo "$DEPLOY_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan github.com >> ~/.ssh/known_hosts
env:
DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}
- name: Push to Repository
run: |
git config --global user.email "${{ secrets.EMAIL }}"
git config --global user.name "${{ secrets.USERNAME }}"
git remote add FicsitRemoteMonitoring [email protected]:V0ID-Whisperer/FicsitRemoteMonitoring.git
git add www
git commit -m "Automatic Push"
git push FicsitRemoteMonitoring main
env:
DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}