TorizonCore container build breaking

I’m attempting to build a Torizon Core image using a containerized build as described Here.

This is failing very early in the process, it appears to be an issue with old versions of repo running on unsupported Python2.

As an aside, is the sudo password for pokyuser documented anywhere? Hard to debug inside the container without this!

Downloading manifest from https://github.com/toradex/toradex-torizon-manifest
remote: Enumerating objects: 3, done.        
remote: Counting objects: 100% (3/3), done.        
remote: Compressing objects: 100% (3/3), done.        
remote: Total 2394 (delta 0), reused 3 (delta 0), pack-reused 2391        
Receiving objects: 100% (2394/2394), 478.82 KiB | 367.00 KiB/s, done.
Resolving deltas: 100% (1514/1514), done.
fatal: manifest 'default.xml' not available
fatal: manifest default.xml not found
repo: warning: Python 2 is no longer supported; Please upgrade to Python 3.6+.

... A new version of repo (2.8) is available.
... New version is available at: /workdir/torizon/.repo/repo/repo
... The launcher is run from: /usr/bin/repo
!!! The launcher is not writable.  Please talk to your sysadmin or distro
!!! to get an update installed.

Traceback (most recent call last):
  File "/workdir/torizon/.repo/repo/main.py", line 628, in <module>
    _Main(sys.argv[1:])
  File "/workdir/torizon/.repo/repo/main.py", line 602, in _Main
    result = run()
  File "/workdir/torizon/.repo/repo/main.py", line 595, in <lambda>
    run = lambda: repo._Run(name, gopts, argv) or 0
  File "/workdir/torizon/.repo/repo/main.py", line 239, in _Run
    copts, cargs = cmd.OptionParser.parse_args(argv)
  File "/workdir/torizon/.repo/repo/command.py", line 71, in OptionParser
    self._Options(self._optparse)
  File "/workdir/torizon/.repo/repo/subcmds/sync.py", line 202, in _Options
    self.jobs = self.manifest.default.sync_j
  File "/workdir/torizon/.repo/repo/manifest_xml.py", line 486, in default
    self._Load()
  File "/workdir/torizon/.repo/repo/manifest_xml.py", line 555, in _Load
    self.manifestProject.worktree))
  File "/workdir/torizon/.repo/repo/manifest_xml.py", line 594, in _ParseManifestXml
    root = xml.dom.minidom.parse(path)
  File "/usr/lib/python2.7/xml/dom/minidom.py", line 1918, in parse
    return expatbuilder.parse(file)
  File "/usr/lib/python2.7/xml/dom/expatbuilder.py", line 922, in parse
    fp = open(file, 'rb')
IOError: [Errno 2] No such file or directory: '/workdir/torizon/.repo/manifest.xml'

Hi @gregb,

Which commands did you execute exactly?

You can access the root permissions by accessing the container using the following command:

docker exec -it -u 0 {DOCKER_ID} bash

Best regards,

Daniel Morais

Hi Daniel,

I ran this:

docker run --rm -it --name=crops -v $PWD:/workdir torizon/crops-toradex --workdir=/workdir --cmd="MACHINE=apalis-imx8 TARGET=torizon-core-docker startup-tdx-torizon.sh"

on this image

REPOSITORY              TAG                 IMAGE ID            CREATED             SIZE
torizon/crops-toradex   latest              7f351604224f        14 months ago       895MB

Thanks for the hint on root user!

Having poked around inside the build container, the old repo or python version do not appear to be the cause.

I think the problem is the BRANCH variable in startup-tdx-torizon.sh. This defaults to “master”, but the master branch in GitHub - toradex/toradex-torizon-manifest: TorizonCore repo manifest has no manifest.xml. If I run with

--cmd="MACHINE=apalis-imx8 TARGET=torizon-core-docker BRANCH=zeus startup-tdx-torizon.sh"

then this has started bitbake and is now happily chugging along. I’ll know some time tomorrow if it works or not!

HI @gregb

Is this issue solved now?

Best regards,
Jaski

Hi Jaski,

We have built our own container solution, using some ideas from the Toradex container and accessing the 5.x.y repo, and it is working fine for us. I’ve not tried any later version of the official container.

Hi @gregb

Perfect that you found a solution. Thanks for the feedback.

Best regards,
Jaski