-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (41 loc) · 1.15 KB
/
sync_qx.yml
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
46
47
name: 同步qx配置
on:
push:
paths:
- 'qx/qx.conf'
workflow_dispatch:
jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4.1.1
with:
fetch-depth: 0
# set python
- name: Set up Python 3.8
uses: actions/setup-python@v2.2.2
with:
python-version: 3.8
# install requirements
- name: Install requirements
working-directory: ./qx/handle
run: |
pip install -r requirements.txt
# sync
- name: Sync
working-directory: ./qx/handle
env:
VPS_DOMAIN: ${{ secrets.VPS_DOMAIN }}
QX_SUBSCRIBE_ID: ${{ secrets.QX_SUBSCRIBE_ID }}
QX_USERNAME: ${{ secrets.VPS_CONFIG_USER }}
QX_PASSWORD: ${{ secrets.VPS_CONFIG_PASS }}
run: |
python convert.py $VPS_DOMAIN $QX_SUBSCRIBE_ID $QX_USERNAME $QX_PASSWORD
- name: Deploy quanx-sub
uses: exuanbo/actions-deploy-gist@v1.1.4
with:
token: ${{ secrets.GH_TOKEN }}
gist_id: ${{ secrets.QX_CONFIG_GIST_ID }}
file_path: qx/qx.conf
file_type: text