Skip to content

Commit 01ea1f7

Browse files
committed
Testsuite: T9014: restrict to amd64/arm64 and require --uefi on arm64
QEMU_CONFIG only defines profiles for amd64 and arm64, and arm64 guests only boot via UEFI, so fail fast with a clear message instead of running into an unsupported-architecture error deep into the install.
1 parent 70deb14 commit 01ea1f7

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

scripts/check-qemu-install

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,13 @@ args = parser.parse_args()
166166
if os.geteuid() != 0:
167167
exit('You need to have root privileges to run this script.')
168168

169+
if platform.machine() not in ['amd64', 'x86_64', 'arm64', 'aarch64']:
170+
exit(f'Unsupported host architecture "{platform.machine()}" - this script '
171+
'only runs on amd64 or arm64 hosts.')
172+
173+
if platform.machine() in ['arm64', 'aarch64'] and not args.uefi:
174+
exit('--uefi is mandatory when running on arm64 hosts.')
175+
169176
if args.cloud_init:
170177
hostname = CI_CONFIG_ARGS['hostname']
171178
op_mode_prompt = rf'vyos@{hostname}:~\$'

0 commit comments

Comments
 (0)