Unable to build UI on non-x86 platforms

Bug #1897821 reported by Lee Trager
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
Medium
Unassigned
maas-ui
Fix Released
Unknown

Bug Description

While investigating a build failure on PPC64 I noticed that the UI is unable to be built on non-x86 platforms. This is because the UI build scripts always download x86_64 NodeJS. We haven't run into this before because the build manager builds a source tarball which actually builds the UI. Since all of us use x86_64 machine we don't run into it. Like MAAS the UI should be able to be built on any supported architecture.

I was able to produce this by trying to build MAAS on the PPC64 machine in the CI.

$ make package
rm -rf /home/ubuntu/build-area
mkdir -p /home/ubuntu/build-area
make -C src/maasui build
make[1]: Entering directory '/home/ubuntu/maas/src/maasui'
yarn --cwd src build-all
/home/ubuntu/maas/src/maasui/nodejs/bin/yarn: 20: exec: node: Exec format error
make[1]: *** [Makefile:37: src/build] Error 2
make[1]: Leaving directory '/home/ubuntu/maas/src/maasui'
make: *** [Makefile:149: src/maasui/build] Error 2
$ uname -a
Linux PPC64 5.4.0-48-generic #52-Ubuntu SMP Thu Sep 10 11:02:31 UTC 2020 ppc64le ppc64le ppc64le GNU/Linux
$ file /home/ubuntu/maas/src/maasui/nodejs/bin/node
/home/ubuntu/maas/src/maasui/nodejs/bin/node: ELF 64-bit LSB executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 2.6.32, BuildID[sha1]=55ed8211666f9ccba08369dc9507a3d65fcc09d3, with debug_info, not stripped

Tags: ui
Lee Trager (ltrager)
description: updated
summary: - Unable to build UI on non-x86 platform
+ Unable to build UI on non-x86 platforms
Changed in maas-ui:
importance: Undecided → Unknown
Revision history for this message
Kit Randel (blr) wrote :

Hey Lee, it looks like there's a tarball provided for PPC LE:

e.g. https://nodejs.org/dist/v12.18.4/node-v12.18.4-linux-ppc64le.tar.xz
https://nodejs.org/en/download/

Changed in maas-ui:
status: New → Fix Released
Changed in maas:
status: Confirmed → Triaged
Lee Trager (ltrager)
Changed in maas:
milestone: 2.9.0b4 → 2.9.0b7
Lee Trager (ltrager)
Changed in maas:
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.