Skip to content

Commit f96077d

Browse files
blind-oracleIDX GitHub Automation
andauthored
feat(BOUN-1233): rework ic-boundary CLI, bump ic-gateway (#2451)
* Rework `ic-boundary` CLI: re-group & rename, move http client & server CLI to `ic-bn-lib` * `ic-boundary` now gets configured through env vars like `ic-gateway` * Add & enable shedding (for now only the system one) for API BNs misc: * Bump the size limits of governance and ledger canisters because the dependencies affect their sizes and throw over the limit --------- Co-authored-by: IDX GitHub Automation <infra+github-automation@dfinity.org>
1 parent 48f45c1 commit f96077d

File tree

28 files changed

+4644
-2526
lines changed

28 files changed

+4644
-2526
lines changed

Cargo.Bazel.Fuzzing.json.lock

Lines changed: 1640 additions & 763 deletions
Large diffs are not rendered by default.

Cargo.Bazel.Fuzzing.toml.lock

Lines changed: 315 additions & 185 deletions
Large diffs are not rendered by default.

Cargo.Bazel.json.lock

Lines changed: 1639 additions & 762 deletions
Large diffs are not rendered by default.

Cargo.Bazel.toml.lock

Lines changed: 313 additions & 183 deletions
Large diffs are not rendered by default.

Cargo.lock

Lines changed: 334 additions & 205 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bazel/external_crates.bzl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ def external_crates_repository(name, cargo_lockfile, lockfile, sanitizers_enable
366366
version = "^0.2.2",
367367
),
368368
"clap": crate.spec(
369-
version = "^4.5.18",
369+
version = "^4.5.20",
370370
features = [
371371
"derive",
372372
"string",
@@ -568,7 +568,7 @@ def external_crates_repository(name, cargo_lockfile, lockfile, sanitizers_enable
568568
),
569569
"ic-bn-lib": crate.spec(
570570
git = "https://github.com/dfinity/ic-bn-lib",
571-
rev = "9abf1e385e4a32279de005d0019c17774e164828",
571+
rev = "526d34d15cfbf369d8baf2dae9932aa18d570a1d",
572572
),
573573
"ic-btc-interface": crate.spec(
574574
version = "^0.2.2",
@@ -680,7 +680,7 @@ def external_crates_repository(name, cargo_lockfile, lockfile, sanitizers_enable
680680
version = "^1.31.0",
681681
),
682682
"instant-acme": crate.spec(
683-
version = "^0.7.1",
683+
version = "^0.7.2",
684684
),
685685
"intmap": crate.spec(
686686
version = "^1.1.0",

ic-os/boundary-guestos/context/Dockerfile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ WORKDIR /tmp
2525

2626
# Download and verify ic-gateway
2727
RUN \
28-
curl -L -O https://github.com/dfinity/ic-gateway/releases/download/v0.1.58/ic-gateway_0.1.58_amd64.deb && \
29-
echo "d6939a8e4c473cf5af8f63e3ce577d7685ec2bb89428d925f8a55dc87d7a10c1 ic-gateway_0.1.58_amd64.deb" | sha256sum -c
28+
curl -L -O https://github.com/dfinity/ic-gateway/releases/download/v0.1.59/ic-gateway_0.1.59_amd64.deb && \
29+
echo "2d57c4a6e77f974ce4674ebc631ba5f2c7de0bb4bf05069c5bcffb21ec274ea2 ic-gateway_0.1.59_amd64.deb" | sha256sum -c
3030

3131
#
3232
# Second build stage:
@@ -56,9 +56,9 @@ FROM image-${BUILD_TYPE}
5656

5757
USER root:root
5858

59-
COPY --from=download /tmp/ic-gateway_0.1.58_amd64.deb /tmp/ic-gateway_0.1.58_amd64.deb
60-
RUN dpkg -i --force-confold /tmp/ic-gateway_0.1.58_amd64.deb && \
61-
rm /tmp/ic-gateway_0.1.58_amd64.deb
59+
COPY --from=download /tmp/ic-gateway_0.1.59_amd64.deb /tmp/ic-gateway_0.1.59_amd64.deb
60+
RUN dpkg -i --force-confold /tmp/ic-gateway_0.1.59_amd64.deb && \
61+
rm /tmp/ic-gateway_0.1.59_amd64.deb
6262

6363
RUN mkdir -p /boot/config \
6464
/boot/efi \
Lines changed: 2 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,16 @@
11
[Unit]
2-
Description=IC Boundary Reverse Proxy
2+
Description=IC-Boundary
33
After=network-online.target
44
Wants=network-online.target
55
After=setup-ic-boundary.service
66
BindsTo=setup-ic-boundary.service
77

88
[Service]
9-
LogRateLimitIntervalSec=1ms
10-
LogRateLimitBurst=1000
119
User=root
1210
Group=root
1311
Restart=always
1412
EnvironmentFile=/run/ic-node/etc/default/ic-boundary
15-
ExecStart=/bin/bash -c ' \
16-
/opt/ic/bin/ic-boundary \
17-
--local-store-path /var/opt/registry/store \
18-
--nns-pub-key-pem /run/ic-node/etc/default/nns_public_key.pem \
19-
--nns-urls "${NNS_URL}" \
20-
--http-port 9000 \
21-
--metrics-addr "[::]:9324" \
22-
--log-stdout \
23-
--log-failed-requests-only \
24-
--nftables-system-replicas-path /run/ic-node/etc/nftables/system_replicas.ruleset \
25-
--retry-update-call \
26-
--rate-limit-per-second-per-subnet "1000" \
27-
--http-client-count "2" \
28-
${CACHE_SIZE:+ --cache-size-bytes "${CACHE_SIZE}"} \
29-
${CACHE_ITEM_MAX_SIZE:+ --cache-max-item-size-bytes "${CACHE_ITEM_MAX_SIZE}"} \
30-
${CACHE_TTL:+ --cache-ttl-seconds "${CACHE_TTL}"} \
31-
'
13+
ExecStart=/opt/ic/bin/ic-boundary
3214

3315
[Install]
3416
WantedBy=multi-user.target

ic-os/components/boundary-guestos/opt/ic/bin/setup-ic-boundary.sh

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,21 @@ function generate_config() {
5050

5151
# Generate Configuration
5252
cat >"${ENV_FILE}" <<EOF
53-
NNS_URL=${NNS_URL}
54-
CACHE_SIZE=1073741824
55-
CACHE_ITEM_MAX_SIZE=10485760
56-
CACHE_TTL=1
53+
LISTEN_HTTP_PORT="9000"
54+
NETWORK_HTTP_CLIENT_COUNT="2"
55+
OBS_METRICS_ADDR="[::]:9324"
56+
OBS_LOG_STDOUT="true"
57+
OBS_LOG_FAILED_REQUESTS_ONLY="true"
58+
HTTP_CLIENT_TIMEOUT_CONNECT="3s"
59+
NFTABLES_SYSTEM_REPLICAS_PATH="/run/ic-node/etc/nftables/system_replicas.ruleset"
60+
RETRY_UPDATE_CALL="true"
61+
RATE_LIMIT_PER_SECOND_PER_SUBNET="1000"
62+
REGISTRY_NNS_URLS="${NNS_URL}"
63+
REGISTRY_NNS_PUB_KEY_PEM="/run/ic-node/etc/default/nns_public_key.pem"
64+
REGISTRY_LOCAL_STORE_PATH="/var/opt/registry/store"
65+
CACHE_SIZE="1GB"
66+
CACHE_MAX_ITEM_SIZE="10MB"
67+
CACHE_TTL="1s"
5768
EOF
5869
}
5970

ic-os/components/boundary-guestos/opt/ic/bin/setup-ic-gateway.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,8 @@ ENV="${ENV}"
125125
DOMAIN_APP="${DOMAINS_APP}"
126126
DOMAIN_SYSTEM="${DOMAINS_SYSTEM}"
127127
DOMAIN_API="${DOMAINS_API}"
128-
HTTP_SERVER_LISTEN_PLAIN="[::]:80"
129-
HTTP_SERVER_LISTEN_TLS="[::]:443"
128+
LISTEN_PLAIN="[::]:80"
129+
LISTEN_TLS="[::]:443"
130130
DNS_PROTOCOL="https"
131131
METRICS_LISTEN="[::]:9314"
132132
POLICY_PRE_ISOLATION_CANISTERS="${RUN_DIR}/pre_isolation_canisters.txt"

0 commit comments

Comments
 (0)