|
47 | 47 | - |
|
48 | 48 | source /shared/config/service-addresses
|
49 | 49 | cat /shared/config/service-addresses
|
50 |
| - echo "Awaiting ethereum node at ${ETHEREUM_HOST}" |
51 |
| - until curl -s -X POST -H 'Content-Type: application/json' \ |
52 |
| - -d '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":67}' \ |
53 |
| - ${ETHEREUM_HOST} | grep 0x; do |
54 |
| - echo "Waiting for Ethereum node ${ETHEREUM_HOST}..." |
55 |
| - sleep 5 |
56 |
| - done |
57 |
| - echo "Ethereum node is ready!" |
| 50 | + {{- include "aztec-network.waitForEthereum" . | nindent 14 }} |
58 | 51 | volumeMounts:
|
59 | 52 | - name: config
|
60 | 53 | mountPath: /shared/config
|
|
66 | 59 | - -c
|
67 | 60 | - |
|
68 | 61 | source /shared/config/service-addresses
|
| 62 | + # it is possible that even though we asserted this above, the DNS resolver of *this* pod |
| 63 | + # is not yet ready to resolve the ethereum host. |
| 64 | + # so we need to wait for it to be ready. |
| 65 | + {{- include "aztec-network.waitForEthereum" . | nindent 14 }} |
69 | 66 | if [ "$(cast code --rpc-url ${ETHEREUM_HOST} 0x4e59b44847b379578588920ca78fbf26c0b4956c)" = "0x" ]; then
|
70 | 67 | echo "Deploying Deterministic Deployment Proxy"
|
71 | 68 | cast publish --rpc-url ${ETHEREUM_HOST} 0xf8a58085174876e800830186a08080b853604580600e600039806000f350fe7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe03601600081602082378035828234f58015156039578182fd5b8082525050506014600cf31ba02222222222222222222222222222222222222222222222222222222222222222a02222222222222222222222222222222222222222222222222222222222222222
|
|
82 | 79 | cp /scripts/deploy-l1-contracts.sh /tmp/deploy-l1-contracts.sh
|
83 | 80 | chmod +x /tmp/deploy-l1-contracts.sh
|
84 | 81 | source /shared/config/service-addresses
|
| 82 | + {{- include "aztec-network.waitForEthereum" . | nindent 14 }} |
85 | 83 |
|
86 | 84 | /tmp/deploy-l1-contracts.sh "{{ .Values.aztec.l1Salt }}" "{{ .Values.ethereum.chainId }}" "{{ join "," .Values.validator.validatorAddresses }}"
|
87 | 85 | volumeMounts:
|
|
0 commit comments