Repository navigation
45 lines (45 loc) · 1.57 KB
/
Copy pathdeploy.yml
File metadata and controls
45 lines (45 loc) · 1.57 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
name: deploy
on:
workflow_dispatch:
push:
branches:
- master
permissions:
contents: read
jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: tibdex/github-app-token@0d49dd721133f900ebd5e0dff2810704e8defbc6 # v1.8.2
if: ${{ !env.ACT }}
id: create-app-token
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
if: ${{ env.ACT }}
with:
token: ${{ github.token }}
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
if: ${{ !env.ACT }}
with:
token: ${{ steps.create-app-token.outputs.token }}
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version: '22.12.0'
cache: 'npm'
- name: install dependencies
run: npm install
- name: export data to ./api
run: npm run db:export
- uses: JamesIves/github-pages-deploy-action@164583b9e44b4fc5910e78feb607ea7c98d3c7b9 # 4.1.1
if: ${{ !env.ACT && github.ref == 'refs/heads/master' }}
with:
repository-name: iptv-org/api
branch: gh-pages
folder: .api
token: ${{ steps.create-app-token.outputs.token }}
git-config-name: iptv-bot[bot]
git-config-email: 84861620+iptv-bot[bot]@users.noreply.github.com
commit-message: '[Bot] Deploy to iptv-org/api'
clean: false