Commit 99696da
Build multiarch (x86_64 + aarch64) hived image for mainnet & mirrornet
Add multi-arch production image support. The amd64 image is compiled natively;
the aarch64 image is CROSS-compiled (never emulated) using the buildroot toolchain
and preinstalled aarch64 RocksDB baked into ci-base-image (hive/common-ci-configuration!377).
Dockerfile:
- build stage pinned to --platform=$BUILDPLATFORM so the heavy C++ compile always runs
natively; for $TARGETARCH=arm64 it cross-compiles via $CROSS_ROOT/Toolchain.cmake with the
preinstalled aarch64 vendor RocksDB. Cross-build specifics: unset the x64 OPENSSL_* env so
find_package(OpenSSL) hits the sysroot; provide a static qemu-aarch64 (CMAKE emulator) so
the assertion-id generators run; export the cross CC/CXX/AR/LD so fc's autotools secp256k1
cross-compiles; force-static readline/ncurses so hived needs only glibc at runtime.
- instance stage parameterised by INSTANCE_BASE_IMAGE and built --platform=$TARGETPLATFORM.
Default keeps the pre-published minimal-runtime image (x64 fast path); multiarch builds set
INSTANCE_BASE_IMAGE=minimal-runtime to build the runtime inline per-arch from ubuntu:24.04.
- TEMPORARY: CI_BASE_IMAGE pinned to the cci!377 image; repoint after that MR merges.
build_instance.sh: HIVE_BUILD_PLATFORMS triggers a multi-arch manifest build (--platform,
--push, inline runtime base); single-arch --load path unchanged.
.gitlab-ci.yaml: gated prepare_hived_image_multiarch (mainnet) and mirrornet_node_build_multiarch
jobs, restricted via rules to develop / master / protected tags / manual BUILD_MULTIARCH=true,
so feature/MR pipelines stay x86_64-only. The single-arch jobs keep running every pipeline.
Depends on hive/common-ci-configuration!377.
Validated locally against the cci!377 image: aarch64 build stage builds 620/620 using the
preinstalled RocksDB, and the assembled aarch64 mainnet image runs hived/cli_wallet (glibc-only
runtime deps).1 parent 55efd7e commit 99696da
8 files changed
Lines changed: 510 additions & 29 deletions
File tree
- doc
- aarch64
- scripts
- ci-helpers
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
247 | 247 | | |
248 | 248 | | |
249 | 249 | | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
250 | 313 | | |
251 | 314 | | |
252 | 315 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | | - | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
34 | 38 | | |
35 | 39 | | |
36 | 40 | | |
37 | | - | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
38 | 44 | | |
39 | 45 | | |
40 | 46 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
13 | 19 | | |
14 | 20 | | |
15 | 21 | | |
| |||
51 | 57 | | |
52 | 58 | | |
53 | 59 | | |
54 | | - | |
55 | | - | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
56 | 69 | | |
57 | 70 | | |
58 | 71 | | |
| |||
89 | 102 | | |
90 | 103 | | |
91 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
92 | 114 | | |
93 | 115 | | |
94 | 116 | | |
95 | 117 | | |
| 118 | + | |
96 | 119 | | |
97 | 120 | | |
98 | 121 | | |
| |||
105 | 128 | | |
106 | 129 | | |
107 | 130 | | |
108 | | - | |
| 131 | + | |
109 | 132 | | |
110 | 133 | | |
111 | 134 | | |
| |||
0 commit comments