Skip to content

Commit 1dd14a5

Browse files
committed
Merge branch 'rjb/alternative-nns-domains' into 'master'
chore(BOUN-779): Updating initial NNS URL for Node Onboarding Currently, a node will try to contact the IC using `nns.ic0.app`. However, the Boundary Node will soon only provide the API endpoints under `ic0.app`, `icp0.io`, and `icp-api.io`, and not the subdomains anymore. As part of this change, we provide multiple domains for redundancy. `setupos` checks that at least one of them works before proceeding. See merge request dfinity-lab/public/ic!12570
2 parents d4f975f + 4b41a48 commit 1dd14a5

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

ic-os/setupos/data/deployment.json.template

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"hosts": "elasticsearch-node-0.mercury.dfinity.systems:443 elasticsearch-node-1.mercury.dfinity.systems:443 elasticsearch-node-2.mercury.dfinity.systems:443 elasticsearch-node-3.mercury.dfinity.systems:443"
77
},
88
"nns": {
9-
"url": "https://nns.ic0.app"
9+
"url": "https://icp-api.io,https://icp0.io,https://ic0.app"
1010
},
1111
"dns": {
1212
"name_servers": "2606:4700:4700::1111 2606:4700:4700::1001 2001:4860:4860::8888 2001:4860:4860::8844"

ic-os/setupos/rootfs/opt/ic/bin/network.sh

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,8 @@ function ping_ipv6_gateway() {
147147
}
148148

149149
function assemble_nns_nodes_list() {
150-
NNS_URL=$(/opt/ic/bin/fetch-property.sh --key=.nns.url --config=${DEPLOYMENT})
151-
NNS_URL_LIST=$(echo $NNS_URL | sed 's@,@ @g')
150+
NNS_URL_STRING=$(/opt/ic/bin/fetch-property.sh --key=.nns.url --config=${DEPLOYMENT})
151+
NNS_URL_LIST=$(echo $NNS_URL_STRING | sed 's@,@ @g')
152152
}
153153

154154
function query_nns_nodes() {
@@ -157,10 +157,8 @@ function query_nns_nodes() {
157157
i=0
158158
success=0
159159
nodes=$(echo ${NNS_URL_LIST} | wc -w)
160+
# At least one of the provided URLs needs to work.
160161
verify=1
161-
if [ ${nodes} -gt 1 ]; then
162-
verify=$(awk "BEGIN {printf \"%.0f\n\", ${nodes}*0.20}")
163-
fi
164162
for url in $(echo $NNS_URL_LIST); do
165163
# When running against testnets, we need to ignore self signed certs
166164
# with `--insecure`. This check is only meant to confirm from SetupOS

0 commit comments

Comments
 (0)