Skip to content

CI: Introduce 2 stages: Prepare image, build the source & upload artifacts

Michael Friedrich requested to merge dnsmichi/zion-firmware:ci/pipeline into master

I've analysed the forum question and forked the repository to dive deeper into the build error.

Here's some things I have now adopted from these findings:

  • Fixing the make command is not the right approach, since the command is executed in the wrong context.
  • 2 stages are needed:
    • First, build the container image and push it to the registry
    • Second, pull the image and run a container with it, build the source in there
  • The path logic with cd inside the build script needed fixes. I've also renamed test.sh into build.sh to have a better name.
  • The generated artifacts were not uploaded, I have now added an example for thermo/*.bin. Reverse engineering Makefiles is not fun ;-)

The provided Dockerfile is awesome, and ready to use.

Merge request reports