This repository was archived by the owner on Sep 8, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
153 lines (132 loc) · 6.09 KB
/
Copy pathlocal-validator.yml
File metadata and controls
153 lines (132 loc) · 6.09 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
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
name: local-validator
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
env:
SOLANA_CLI: v3.0.12
jobs:
test-doublezero-solana-fork:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check disk space before cleanup
run: df -h
- name: Free disk space
run: |
sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
sudo docker image prune --all --force
sudo docker builder prune -a --force
- name: Check disk space after cleanup
run: df -h
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Solana toolchain
run: |
sh -c "$(curl -sSfL https://release.anza.xyz/$SOLANA_CLI/install)"
echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH
- name: Generate ~/.config/solana/id.json
run: solana-keygen new --silent --no-bip39-passphrase
- name: Generate manager keypair for synthetic ValidatorClientRewards
run: solana-keygen new --silent --no-bip39-passphrase -o manager_keypair.json
- name: Start Solana mainnet-beta fork in background
run: |
MANAGER_PUBKEY=$(solana address -k manager_keypair.json)
cargo run --bin doublezero-solana-fork -- -um --reset --synthetic-validator-client-rewards-manager "$MANAGER_PUBKEY" > /dev/null 2>&1 &
- name: Build `doublezero-solana`
run: cargo build --bin doublezero-solana
- name: Run `doublezero-solana` tests
run: bash sh/test_doublezero_solana_fork.sh
test-doublezero-solana-validator-debt-fork-current:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check disk space before cleanup
run: df -h
- name: Free disk space
run: |
sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
sudo docker image prune --all --force
sudo docker builder prune -a --force
- name: Check disk space after cleanup
run: df -h
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Solana toolchain
run: |
sh -c "$(curl -sSfL https://release.anza.xyz/$SOLANA_CLI/install)"
echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH
- name: Generate ~/.config/solana/id.json
run: solana-keygen new --silent --no-bip39-passphrase
- name: Start Solana mainnet-beta fork in background
run: cargo run --bin doublezero-solana-fork -- -um --reset --god-mode > /dev/null 2>&1 &
- name: Build `doublezero-revenue-distribution-admin` and `doublezero-solana-validator-debt`
run: cargo build --bin doublezero-revenue-distribution-admin --bin doublezero-solana-validator-debt --bin doublezero-solana
- name: Run `doublezero-solana-validator-debt` tests
run: bash sh/test_validator_debt_fork.sh
# Commenting out as we may bring this back in the future
# test-full-debt-flow:
# runs-on: ubuntu-latest
# needs: [test-doublezero-solana-validator-debt-fork-current]
# steps:
# - uses: actions/checkout@v4
# - name: Check disk space before cleanup
# run: df -h
# - name: Free disk space
# run: |
# sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
# sudo docker image prune --all --force
# sudo docker builder prune -a --force
# - name: Check disk space after cleanup
# run: df -h
# - uses: dtolnay/rust-toolchain@stable
# - uses: Swatinem/rust-cache@v2
# - name: Solana toolchain
# run: |
# sh -c "$(curl -sSfL https://release.anza.xyz/$SOLANA_CLI/install)"
# echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH
# - name: Generate ~/.config/solana/id.json
# run: solana-keygen new --silent --no-bip39-passphrase
# - name: Build binaries
# run: |
# cargo build --bin doublezero-solana \
# --bin doublezero-solana-validator-debt \
# --bin doublezero-revenue-distribution-admin \
# --bin doublezero-solana-fork
# - name: Start Solana mainnet-beta fork in background
# run: cargo run --bin doublezero-solana-fork -- -um --reset --god-mode > /dev/null 2>&1 &
# - name: Run full debt flow test
# run: CI=1 SKIP_FORK_START=1 bash sh/test_full_debt_flow.sh
# timeout-minutes: 10
# - name: Run Rust integration tests
# run: cargo test --features integration -p doublezero-solana-validator-debt
# timeout-minutes: 5
test-doublezero-solana-validator-debt-fork-override-76:
if: false
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check disk space before cleanup
run: df -h
- name: Free disk space
run: |
sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL
sudo docker image prune --all --force
sudo docker builder prune -a --force
- name: Check disk space after cleanup
run: df -h
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Solana toolchain
run: |
sh -c "$(curl -sSfL https://release.anza.xyz/$SOLANA_CLI/install)"
echo "$HOME/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH
- name: Generate ~/.config/solana/id.json
run: solana-keygen new --silent --no-bip39-passphrase
- name: Start Solana mainnet-beta fork in background
run: cargo run --bin doublezero-solana-fork -- -um --reset --god-mode --next-completed-dz-epoch-override 76 > /dev/null 2>&1 &
- name: Build `doublezero-revenue-distribution-admin` and `doublezero-solana-validator-debt`
run: cargo build --bin doublezero-revenue-distribution-admin --bin doublezero-solana-validator-debt
- name: Run `doublezero-solana-validator-debt` tests
run: bash sh/test_validator_debt_fork.sh