forked from LedgerHQ/ledger-live
-
Notifications
You must be signed in to change notification settings - Fork 1
83 lines (80 loc) · 2.65 KB
/
bot-portfolio-report.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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
name: "Bots Portfolio"
on:
workflow_dispatch:
inputs:
seeds:
description: "comma separated list of seed indexes to filter on (e.g. 1,2,3) – all if not filtered"
required: false
currencies:
description: "a comma separated list of currencies to filter (if provided)."
required: false
families:
description: "a comma separated list of families to filter (if provided)."
required: false
push:
branches:
- support/bots-portfolio
- support/bots-portfolio-*
schedule:
- cron: "30 5 * * *"
permissions:
id-token: write
contents: read
jobs:
portfolio:
runs-on: [ledger-live-medium]
steps:
- name: generate token
id: generate-token
uses: tibdex/github-app-token@v1
with:
app_id: ${{ secrets.GH_BOT_APP_ID }}
private_key: ${{ secrets.GH_BOT_PRIVATE_KEY }}
- uses: actions/checkout@v4
- name: Retrieving coin apps
uses: actions/checkout@v4
with:
ref: generated/ledger-live-bot
repository: LedgerHQ/coin-apps
token: ${{ steps.generate-token.outputs.token }}
path: coin-apps
- name: Setup the toolchain
uses: LedgerHQ/ledger-live/tools/actions/composites/setup-toolchain@develop
with:
accountId: ${{ secrets.AWS_ACCOUNT_ID_PROD }}
roleName: ${{ secrets.AWS_CACHE_ROLE_NAME }}
region: ${{ secrets.AWS_CACHE_REGION }}
- name: install and build
run: |
pnpm i --filter="live-cli..." --filter="ledger-live"
pnpm build:llc
shell: bash
- name: portfolio
timeout-minutes: 200
env:
SEED1: ${{ secrets.SEED1 }}
SEED2: ${{ secrets.SEED2 }}
SEED3: ${{ secrets.SEED3 }}
SEED4: ${{ secrets.SEED4 }}
SEED5: ${{ secrets.SEED5 }}
SEED6: ${{ secrets.SEED6 }}
SEED7: ${{ secrets.SEED7 }}
FILTER_CURRENCIES: ${{ github.event.inputs.currencies }}
FILTER_FAMILIES: ${{ github.event.inputs.families }}
FILTER_SEEDS: ${{ github.event.inputs.seeds }}
DEFAULT_FILTER_SEEDS: "1,2,3,4,5"
PARALLEL: 4
NODE_OPTIONS: "--max-old-space-size=7168"
REPORT_FOLDER: reports
run: |
export COINAPPS=$PWD/coin-apps
export SUMMARY=$GITHUB_STEP_SUMMARY
export NODE_ENV=production
cd libs/ledger-live-common
node lib/bot/portfolio/process-main.js
shell: bash
- name: upload reports
uses: actions/upload-artifact@v4
with:
name: reports
path: libs/ledger-live-common/reports