Compare commits
19 Commits
04a2140213
...
7fae419708
| Author | SHA1 | Date | |
|---|---|---|---|
| 7fae419708 | |||
| ef6877768a | |||
| dbb10b7708 | |||
| f4145b911a | |||
| 2251f076c6 | |||
| 64b5f761d5 | |||
| 39bede38d3 | |||
| db49e74110 | |||
| ad66ae1b46 | |||
| 723c0cbb3a | |||
| 73620f0777 | |||
| cbbae112dc | |||
| 7f28f7bf81 | |||
| e54d5ef3c2 | |||
| d154fed609 | |||
| f12c8c050a | |||
| 3366b46039 | |||
| ec0608cc7c | |||
| 00a0613f13 |
48
.gitea/workflows/deploy.yml
Normal file
48
.gitea/workflows/deploy.yml
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
name: deploy to server
|
||||||
|
|
||||||
|
on: push
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-and-deploy:
|
||||||
|
runs-on: node22-build
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v5
|
||||||
|
- name: Setup pnpm
|
||||||
|
uses: pnpm/action-setup@v4
|
||||||
|
with:
|
||||||
|
version: 10
|
||||||
|
- name: Setup node 22
|
||||||
|
uses: actions/setup-node@v5
|
||||||
|
with:
|
||||||
|
node-version: '22'
|
||||||
|
cache: 'pnpm'
|
||||||
|
- name: Cache pnpm store
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: ~/.pnpm-store
|
||||||
|
key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-pnpm-
|
||||||
|
- name: Install dependencies
|
||||||
|
run: pnpm install
|
||||||
|
- name: Cache Nuxt build
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: .nuxt
|
||||||
|
key: ${{ runner.os }}-nuxt-${{ hashFiles('pnpm-lock.yaml') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-nuxt-
|
||||||
|
- name: Build project
|
||||||
|
run: pnpm run build
|
||||||
|
- name: Deploy to server
|
||||||
|
if: github.ref == 'refs/heads/master'
|
||||||
|
uses: easingthemes/ssh-deploy@main
|
||||||
|
with:
|
||||||
|
ARGS: "-rlgoDzvc -i --delete"
|
||||||
|
REMOTE_HOST: ${{ secrets.rsync_host }}
|
||||||
|
REMOTE_USER: ${{ secrets.rsync_username }}
|
||||||
|
SOURCE: ${{ secrets.rsync_source }}
|
||||||
|
TARGET: ${{ secrets.rsync_destination }}
|
||||||
|
SSH_PRIVATE_KEY: ${{ secrets.rsync_key }}
|
||||||
|
SCRIPT_AFTER: ${{ secrets.script_after_rsync }}
|
||||||
Reference in New Issue
Block a user