-
Notifications
You must be signed in to change notification settings - Fork 7
59 lines (53 loc) · 1.84 KB
/
deploy-protocol.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
name: "Deploy Protocol"
env:
API_KEY_ARBISCAN: ${{ secrets.API_KEY_ARBISCAN }}
API_KEY_BSCSCAN: ${{ secrets.API_KEY_BSCSCAN }}
API_KEY_ETHERSCAN: ${{ secrets.API_KEY_ETHERSCAN }}
API_KEY_GNOSISSCAN: ${{ secrets.API_KEY_GNOSISSCAN }}
API_KEY_INFURA: ${{ secrets.API_KEY_INFURA }}
API_KEY_OPTIMISTIC_ETHERSCAN: ${{ secrets.API_KEY_OPTIMISTIC_ETHERSCAN }}
API_KEY_POLYGONSCAN: ${{ secrets.API_KEY_POLYGONSCAN }}
API_KEY_SNOWTRACE: ${{ secrets.API_KEY_SNOWTRACE }}
FOUNDRY_OPTIMIZER_RUNS: "4000" # needed to compile V2 Core
FOUNDRY_PROFILE: "optimized"
MNEMONIC: ${{ secrets.MNEMONIC }}
RPC_URL_GOERLI: ${{ secrets.RPC_URL_GOERLI }}
on:
workflow_dispatch:
inputs:
admin:
default: "0xF3663da48030b6c88535413Fd643aB0B5F3496ff"
description: "Initial protocol admin."
required: false
chain:
default: "goerli"
description: "Chain name as defined in the Foundry config."
required: false
max-segment-count:
default: "300"
description: "Maximum number of segments allowed in a stream."
required: false
jobs:
deploy-protocol:
runs-on: "ubuntu-latest"
steps:
- name: "Check out the repo"
uses: "actions/checkout@v3"
with:
submodules: "recursive"
token: ${{ secrets.CI_TOKEN }}
- name: "Install Foundry"
uses: "foundry-rs/foundry-toolchain@v1"
- name: "Deploy the Sablier V2 Protocol"
run: >-
forge script script/DeployProtocol.s.sol
--broadcast
--rpc-url "${{ inputs.chain }}"
--sig "run(address,uint256)"
"${{ inputs.admin }}"
"${{ inputs.max-segment-count }}"
-vvvv
- name: "Add workflow summary"
run: |
echo "## Result" >> $GITHUB_STEP_SUMMARY
echo "✅ Done" >> $GITHUB_STEP_SUMMARY