You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The documentation proposes to use bind mounts and the problem with those is that the geekotest user ends up with a different UID compared to the same user on the host machine.
uid=496(geekotest) #webui container
uid=496(systemd-bus-proxy) #worker container
uid=496(nscd) #host OS
As a result there are complications where openQA tries to access this data (Save, Upload, etc). This can be fixed by this solution or by using persistent named data volumes.
In the following example I am using a data volume, called Assets and another one called Tests.
Create the default fake authentication keys: curl -X POST http://localhost:80/login Notice: for this one, I would recommend to install curl in the image and do it from there
As you can see, this data is now accessible between the two containers via the --volumes-from parameter and also in the host system:
# docker exec -it openqa_webui ls -l /var/lib/openqa/share/tests/ | tail -n 1
drwxr-xr-x 1 geekotest nogroup 194 Jan 11 10:19 opensuse
# docker exec -it openqa_worker ls -l /var/lib/openqa/share/tests/ | tail -n 1
drwxr-xr-x 1 systemd-bus-proxy nobody 194 Jan 11 10:19 opensuse
# ls -l /var/lib/docker/volumes/Tests/_data | tail -n 1
drwxr-xr-x 1 nscd nobody 194 Jan 11 11:19 opensuse
# docker exec -it openqa_webui ls -l /var/lib/openqa/share/factory/{iso,hdd} | grep '-'
-rw-r--r-- 1 geekotest nogroup 1341506560 Jan 11 10:50 opensuse-Tumbleweed-x86_64-20180109-textmode@64bit.qcow2
-rw-r--r-- 1 geekotest nogroup 4577034240 Jan 10 14:49 openSUSE-Tumbleweed-DVD-x86_64-Snapshot20180109-Media.iso
# docker exec -it openqa_worker ls -l /var/lib/openqa/share/factory/{iso,hdd} | grep '-'
-rw-r--r-- 1 systemd-bus-proxy nobody 1341506560 Jan 11 10:50 opensuse-Tumbleweed-x86_64-20180109-textmode@64bit.qcow2
-rw-r--r-- 1 systemd-bus-proxy nobody 4577034240 Jan 10 14:49 openSUSE-Tumbleweed-DVD-x86_64-Snapshot20180109-Media.iso
# ls -l /var/lib/docker/volumes/Assets/_data/{iso,hdd} | grep '-'
-rw-r--r-- 1 nscd nobody 1341506560 Jan 11 11:50 opensuse-Tumbleweed-x86_64-20180109-textmode@64bit.qcow2
-rw-r--r-- 1 nscd nobody 4577034240 Jan 10 15:49 openSUSE-Tumbleweed-DVD-x86_64-Snapshot20180109-Media.iso
However, volumes need manually deletion. You cannot clean them up just be removing the container. It's an extra step, which is implemented this way because of insurances purposes. The point is that this data it's important; at least much more important than the container itself. It's a location for the container to store data that outlive the executable -- that is why we need to name them.
The text was updated successfully, but these errors were encountered:
The documentation proposes to use bind mounts and the problem with those is that the
geekotest
user ends up with a differentUID
compared to the same user on the host machine.As a result there are complications where openQA tries to access this data (Save, Upload, etc). This can be fixed by this solution or by using persistent named data volumes.
In the following example I am using a data volume, called
Assets
and another one calledTests
.Working Example
Start the webui container:
Create the default fake authentication keys:
curl -X POST http://localhost:80/login
Notice: for this one, I would recommend to install
curl
in the image and do it from thereStart the worker container:
Fetch the
source code
of the tests:Now, let's try to
clone
ajob
which requires to download aniso
, write aqcow
image and share it with among the two containers:Debugging
As you can see, this data is now accessible between the two containers via the
--volumes-from
parameter and also in the host system:However, volumes need manually deletion. You cannot clean them up just be removing the container. It's an extra step, which is implemented this way because of insurances purposes. The point is that this data it's important; at least much more important than the container itself. It's a location for the container to store data that outlive the executable -- that is why we need to name them.
The text was updated successfully, but these errors were encountered: