-
Notifications
You must be signed in to change notification settings - Fork 498
50 lines (44 loc) · 1.58 KB
/
grab-coupon.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
48
49
50
name: 领红包
# https://docs.github.com/cn/actions/reference/events-that-trigger-workflows#workflow_dispatch
on:
# 手动触发
workflow_dispatch:
# 定时任务
schedule:
# https://crontab.guru/
# UTC 时间,中国时区应减 8
# ┌────────── minute (0 - 59)
# │ ┌──────── hour (0 - 23)
# │ │ ┌────── day of the month (1 - 31)
# │ │ │ ┌──── month (1 - 12 or JAN-DEC)
# │ │ │ │ ┌── day of the week (0 - 6 or SUN-SAT)
# │ │ │ │ │
- cron: '45 2 * * *'
jobs:
start:
name: grab coupon
runs-on: ubuntu-latest
steps:
- name: Checkout codes
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version-file: 'package.json'
cache: 'yarn'
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Run app
run: yarn start
env:
TOKEN: ${{ secrets.TOKEN }}
BARK_KEY: ${{ secrets.BARK_KEY }}
TG_USER_ID: ${{ secrets.TG_USER_ID }}
TG_BOT_TOKEN: ${{ secrets.TG_BOT_TOKEN }}
SC_SEND_KEY: ${{ secrets.SC_SEND_KEY }}
QMSG_KEY: ${{ secrets.QMSG_KEY }}
QMSG_ADMIN: ${{ secrets.QMSG_ADMIN }}
QYWX_SEND_CONF: ${{ secrets.QYWX_SEND_CONF }}
LARK_WEBHOOK: ${{ secrets.LARK_WEBHOOK }}
PUSHPLUS_TOKEN: ${{ secrets.PUSHPLUS_TOKEN }}
DINGTALK_WEBHOOK: ${{ secrets.DINGTALK_WEBHOOK }}