Skip to content

Commit 6053fef

Browse files
committed
fix sources.py based cross-arch builds
Derive debian_arch from base_arch by default when not set by the user. This ensures that cross-architecture builds correctly download the appropriate binaries, while preserving any explicit user override. Closes-Bug: #2103810 Change-Id: I11b7e19ac3a12147138a98fc1e030767f70b44c9 (cherry picked from commit 915189d)
1 parent 34d537a commit 6053fef

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

kolla/common/config.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -386,6 +386,9 @@ def parse(conf, args, usage=None, prog=None,
386386
openstack_branch_slashed = openstack_branch.replace('-', '/')
387387
conf.set_default('openstack_branch', openstack_branch)
388388
conf.set_default('openstack_branch_slashed', openstack_branch_slashed)
389+
# NOTE(bbezak) Derive debian_arch from base_arch if not set explicitly
390+
derived_arch = 'arm64' if conf.base_arch == 'aarch64' else 'amd64'
391+
conf.set_default('debian_arch', derived_arch)
389392

390393
if not conf.base_image:
391394
conf.base_image = DEFAULT_BASE_TAGS[conf.base]['name']

0 commit comments

Comments
 (0)