2024-03-01 12:31:16 +03:00
|
|
|
name: Gitea Actions Demo
|
|
|
|
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
#on:
|
|
|
|
# push:
|
|
|
|
# branches:
|
|
|
|
# - main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build-and-deploy:
|
|
|
|
runs-on: main
|
|
|
|
steps:
|
|
|
|
- name: Check out repository code
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Build app
|
|
|
|
run: |
|
|
|
|
yarn
|
2024-03-01 12:32:53 +03:00
|
|
|
yarn build
|
2024-03-01 12:31:16 +03:00
|
|
|
- name: Move result to /var/www/koptilnya.xyz
|
2024-03-01 12:32:53 +03:00
|
|
|
run: cp -r .output/. /var/www/koptilnya.xyz
|
|
|
|
- name: Restart PM2 daemon
|
|
|
|
run: pm2 restart koptilnya.xyz
|