Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Use QEMU in GitLab CI instead of Docker image

GitLab CI is highly integrated with Docker.

But sometimes, if the project depends on the interaction with Linux kernel like LUKS. It cannot works properly.

The project cryptsetup use Travis-CI instead of GitLab CI even if it host on gitlab.com. I don't know if it is just personal preference of project maintainer.

Hence is it possible to run QEMU or Firecracker instead of Docker?

Is there any equivalent alternative in GitLab than Travis-CI?

like image 517
Audra Jacot Avatar asked Sep 03 '25 09:09

Audra Jacot


2 Answers

This is not yet supported.

A recent (mid-2019) gitlab-org/gitlab-runner issue 4338 mentions katacontainers with firecracker vms as one possible alternative to Docker Machine, for autoscaling.

But this is still being studied.

like image 160
VonC Avatar answered Sep 05 '25 00:09

VonC


This video shows an approach that uses pytest to run a CI/CD in/on Qemu in GitLab. It parses the CLI output, so it is (still) a bit convoluted. However, I think the video gives a clear and detailed explanation on how it is done.

Here is the archived repository that is used to do so, and here is the accompanying GitHub repository. Hope this helps :)

like image 37
a.t. Avatar answered Sep 05 '25 00:09

a.t.