forked from zama-ai/fhevm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
launch-fhevm.sh
executable file
·33 lines (22 loc) · 1.16 KB
/
launch-fhevm.sh
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
#!/bin/bash
PRIVATE_KEY_GATEWAY_DEPLOYER=$(grep PRIVATE_KEY_GATEWAY_DEPLOYER .env | cut -d '"' -f 2)
npx hardhat task:computePredeployAddress --private-key "$PRIVATE_KEY_GATEWAY_DEPLOYER"
PRIVATE_KEY_GATEWAY_RELAYER=$(grep PRIVATE_KEY_GATEWAY_RELAYER .env | cut -d '"' -f 2)
GATEWAY_CONTRACT_PREDEPLOY_ADDRESS=$(grep GATEWAY_CONTRACT_PREDEPLOY_ADDRESS gateway/.env.gateway | cut -d '=' -f2)
TFHE_EXECUTOR_CONTRACT_ADDRESS=$(grep TFHE_EXECUTOR_CONTRACT_ADDRESS lib/.env.exec | cut -d '=' -f2)
docker run -d -i -p 8545:8545 --rm --name fhevm \
-e PRIVATE_KEY_ORACLE_RELAYER="$PRIVATE_KEY_ORACLE_RELAYER" \
-e ORACLE_CONTRACT_PREDEPLOY_ADDRESS="$ORACLE_CONTRACT_PREDEPLOY_ADDRESS" \
-e TFHE_EXECUTOR_CONTRACT_ADDRESS="$TFHE_EXECUTOR_CONTRACT_ADDRESS" \
ghcr.io/zama-ai/ethermint-dev-node:v0.5.0-1
sleep 10
npx hardhat task:computeACLAddress
npx hardhat task:computeTFHEExecutorAddress
npx hardhat task:computeKMSVerifierAddress
npx hardhat task:deployACL
npx hardhat task:deployTFHEExecutor
npx hardhat task:deployKMSVerifier
npx hardhat compile:specific --contract lib
npx hardhat compile:specific --contract gateway
npx hardhat task:launchFhevm
docker attach fhevm