Hi Lava users,
Is it possible to run commands inside a lava job test-section, locally, from a Lava Job? Ex: cd /media/sh_shared_folders docker build -t tradefed .
We have the following setup:
* A machine with Linux Ubuntu; * an Oracle Virtual Box VM on the machine with a Xubuntu distro image * inside the VM we have created 3 Docker containers:
* one with the Jenkins * second one with Lava * third is created for the purpose of running Google TradeFederation against the Android device
(The AOSP source tree is available to the VM via shared_folders and the docker container has also access to it. (via docker run -v dir_host:dir_container) )
What we what to achieve is to have 2 jobs in Lava :
* one for building the Docker image for the purpose of building TradeFederation inside Ex. Running these commande locally:
source ./build/make/envsetup.sh lunch <device-target> make tradefed-all -j8
* second using the above image, instantiate, create a container which should run TradeFederation against the android device connected to the machine
What I need is to be able to run commands locally inside the VM (on Xubuntu distro) from a Lava job. For these we have to somehow not send the command to qemu but run them locally. Is this possible? If yes, how can we achieve this?
George Nistor
George,
Do I understand correctly you would like to use LAVA as a building tool?
milosz
On Thu, 8 Aug 2019 at 10:47, George Nistor george.n@l4b-software.com wrote:
Hi Lava users,
Is it possible to run commands inside a lava job test-section, locally, from a Lava Job?
Ex:
cd /media/sh_shared_folders
docker build -t tradefed .
We have the following setup:
A machine with Linux Ubuntu; an Oracle Virtual Box VM on the machine with a Xubuntu distro image inside the VM we have created 3 Docker containers:
one with the Jenkins second one with Lava third is created for the purpose of running Google TradeFederation against the Android device
(The AOSP source tree is available to the VM via shared_folders and the docker container has also access to it. (via docker run -v dir_host:dir_container) )
What we what to achieve is to have 2 jobs in Lava :
one for building the Docker image for the purpose of building TradeFederation inside
Ex. Running these commande locally: source ./build/make/envsetup.sh lunch <device-target> make tradefed-all -j8
second using the above image, instantiate, create a container which should run TradeFederation against the android device connected to the machine
What I need is to be able to run commands locally inside the VM (on Xubuntu distro) from a Lava job. For these we have to somehow not send the command to qemu but run them locally.
Is this possible? If yes, how can we achieve this?
George Nistor
Lava-users mailing list Lava-users@lists.lavasoftware.org https://lists.lavasoftware.org/mailman/listinfo/lava-users
Yes For one job to build tradefederation from inside a docker container. For the second job to run Google TradeFederation from the docker container.
Would be that possible with Lava?
george
-----Original Message----- From: Milosz Wasilewski milosz.wasilewski@linaro.org Sent: Thursday, August 8, 2019 1:16 PM To: George Nistor george.n@l4b-software.com Cc: lava-users@lists.lavasoftware.org Subject: Re: [Lava-users] running commands locally from a Lava job
George,
Do I understand correctly you would like to use LAVA as a building tool?
milosz
On Thu, 8 Aug 2019 at 10:47, George Nistor george.n@l4b-software.com wrote:
Hi Lava users,
Is it possible to run commands inside a lava job test-section, locally, from a Lava Job?
Ex:
cd /media/sh_shared_folders
docker build -t tradefed .
We have the following setup:
A machine with Linux Ubuntu; an Oracle Virtual Box VM on the machine with a Xubuntu distro image inside the VM we have created 3 Docker containers:
one with the Jenkins second one with Lava third is created for the purpose of running Google TradeFederation against the Android device
(The AOSP source tree is available to the VM via shared_folders and the docker container has also access to it. (via docker run -v dir_host:dir_container) )
What we what to achieve is to have 2 jobs in Lava :
one for building the Docker image for the purpose of building TradeFederation inside
Ex. Running these commande locally: source
./build/make/envsetup.sh
lunch
<device-target>
make
tradefed-all -j8
second using the above image, instantiate, create a container which should run TradeFederation against the android device connected to the machine
What I need is to be able to run commands locally inside the VM (on Xubuntu distro) from a Lava job. For these we have to somehow not send the command to qemu but run them locally.
Is this possible? If yes, how can we achieve this?
George Nistor
Lava-users mailing list Lava-users@lists.lavasoftware.org https://lists.lavasoftware.org/mailman/listinfo/lava-users
I would say it's a bad idea. LAVA is not meant for building stuff. It can do that but you will need to hack around quite a lot. Secondly IIUC you need to have dependency between build and run steps. If you want to implement this using LAVA this implies multi-node job. There is no other way LAVA will manage dependencies and timings between executions. So this is getting pretty complicated already.
LAVA is already running tradefed jobs (CTS and VTS) using real hardware and it's a pretty common use case. There are 2 implementations of this. One is using single node job with LXC container acting as a host side. Other is using multinode and can shard tests between multiple devices. However tradefed packages are built outside of lava and downloaded before job starts.
To sum up, I think what you're trying to do is not best suited for LAVA. However it might be possible given some effort spent on experimenting.
milosz
On Thu, 8 Aug 2019 at 11:20, George Nistor george.n@l4b-software.com wrote:
Yes For one job to build tradefederation from inside a docker container. For the second job to run Google TradeFederation from the docker container.
Would be that possible with Lava?
george
-----Original Message----- From: Milosz Wasilewski milosz.wasilewski@linaro.org Sent: Thursday, August 8, 2019 1:16 PM To: George Nistor george.n@l4b-software.com Cc: lava-users@lists.lavasoftware.org Subject: Re: [Lava-users] running commands locally from a Lava job
George,
Do I understand correctly you would like to use LAVA as a building tool?
milosz
On Thu, 8 Aug 2019 at 10:47, George Nistor george.n@l4b-software.com wrote:
Hi Lava users,
Is it possible to run commands inside a lava job test-section, locally, from a Lava Job?
Ex:
cd /media/sh_shared_folders
docker build -t tradefed .
We have the following setup:
A machine with Linux Ubuntu; an Oracle Virtual Box VM on the machine with a Xubuntu distro image inside the VM we have created 3 Docker containers:
one with the Jenkins second one with Lava third is created for the purpose of running Google TradeFederation against the Android device
(The AOSP source tree is available to the VM via shared_folders and the docker container has also access to it. (via docker run -v dir_host:dir_container) )
What we what to achieve is to have 2 jobs in Lava :
one for building the Docker image for the purpose of building TradeFederation inside
Ex. Running these commande locally: source
./build/make/envsetup.sh
lunch
<device-target>
make
tradefed-all -j8
second using the above image, instantiate, create a container which should run TradeFederation against the android device connected to the machine
What I need is to be able to run commands locally inside the VM (on Xubuntu distro) from a Lava job. For these we have to somehow not send the command to qemu but run them locally.
Is this possible? If yes, how can we achieve this?
George Nistor
Lava-users mailing list Lava-users@lists.lavasoftware.org https://lists.lavasoftware.org/mailman/listinfo/lava-users
Thanks for the answers,
1. What do you mean by "with LXC container acting as a host side ". It is an LXC container on the machine where Lava runs and inside this containes runs Tradefed? 2. Where can I find an example of these Jobs? Could you help me with an link, or sample jobs?
george
-----Original Message----- From: Milosz Wasilewski milosz.wasilewski@linaro.org Sent: Thursday, August 8, 2019 1:29 PM To: George Nistor george.n@l4b-software.com Cc: lava-users@lists.lavasoftware.org Subject: Re: [Lava-users] running commands locally from a Lava job
I would say it's a bad idea. LAVA is not meant for building stuff. It can do that but you will need to hack around quite a lot. Secondly IIUC you need to have dependency between build and run steps. If you want to implement this using LAVA this implies multi-node job. There is no other way LAVA will manage dependencies and timings between executions. So this is getting pretty complicated already.
LAVA is already running tradefed jobs (CTS and VTS) using real hardware and it's a pretty common use case. There are 2 implementations of this. One is using single node job with LXC container acting as a host side. Other is using multinode and can shard tests between multiple devices. However tradefed packages are built outside of lava and downloaded before job starts.
To sum up, I think what you're trying to do is not best suited for LAVA. However it might be possible given some effort spent on experimenting.
milosz
On Thu, 8 Aug 2019 at 11:20, George Nistor george.n@l4b-software.com wrote:
Yes For one job to build tradefederation from inside a docker container. For the second job to run Google TradeFederation from the docker container.
Would be that possible with Lava?
george
-----Original Message----- From: Milosz Wasilewski milosz.wasilewski@linaro.org Sent: Thursday, August 8, 2019 1:16 PM To: George Nistor george.n@l4b-software.com Cc: lava-users@lists.lavasoftware.org Subject: Re: [Lava-users] running commands locally from a Lava job
George,
Do I understand correctly you would like to use LAVA as a building tool?
milosz
On Thu, 8 Aug 2019 at 10:47, George Nistor george.n@l4b-software.com wrote:
Hi Lava users,
Is it possible to run commands inside a lava job test-section, locally, from a Lava Job?
Ex:
cd /media/sh_shared_folders
docker build -t tradefed .
We have the following setup:
A machine with Linux Ubuntu; an Oracle Virtual Box VM on the machine with a Xubuntu distro image inside the VM we have created 3 Docker containers:
one with the Jenkins second one with Lava third is created for the purpose of running Google TradeFederation against the Android device
(The AOSP source tree is available to the VM via shared_folders and the docker container has also access to it. (via docker run -v dir_host:dir_container) )
What we what to achieve is to have 2 jobs in Lava :
one for building the Docker image for the purpose of building TradeFederation inside
Ex. Running these commande locally: source
./build/make/envsetup.sh
lunch
<device-target>
make
tradefed-all -j8
second using the above image, instantiate, create a container which should run TradeFederation against the android device connected to the machine
What I need is to be able to run commands locally inside the VM (on Xubuntu distro) from a Lava job. For these we have to somehow not send the command to qemu but run them locally.
Is this possible? If yes, how can we achieve this?
George Nistor
Lava-users mailing list Lava-users@lists.lavasoftware.org https://lists.lavasoftware.org/mailman/listinfo/lava-users
On Thu, 8 Aug 2019 at 11:50, George Nistor george.n@l4b-software.com wrote:
Thanks for the answers,
- What do you mean by "with LXC container acting as a host side ". It is an LXC container on the machine where Lava runs and inside this containes runs Tradefed?
yes, exactly. Here is an example job definition: https://gist.github.com/mwasilew/e6e80a351d43388b1c3342098012ec5c
I can't share the actual job and logs as there are passwords included.
milosz
- Where can I find an example of these Jobs? Could you help me with an link, or sample jobs?
george
-----Original Message----- From: Milosz Wasilewski milosz.wasilewski@linaro.org Sent: Thursday, August 8, 2019 1:29 PM To: George Nistor george.n@l4b-software.com Cc: lava-users@lists.lavasoftware.org Subject: Re: [Lava-users] running commands locally from a Lava job
I would say it's a bad idea. LAVA is not meant for building stuff. It can do that but you will need to hack around quite a lot. Secondly IIUC you need to have dependency between build and run steps. If you want to implement this using LAVA this implies multi-node job. There is no other way LAVA will manage dependencies and timings between executions. So this is getting pretty complicated already.
LAVA is already running tradefed jobs (CTS and VTS) using real hardware and it's a pretty common use case. There are 2 implementations of this. One is using single node job with LXC container acting as a host side. Other is using multinode and can shard tests between multiple devices. However tradefed packages are built outside of lava and downloaded before job starts.
To sum up, I think what you're trying to do is not best suited for LAVA. However it might be possible given some effort spent on experimenting.
milosz
On Thu, 8 Aug 2019 at 11:20, George Nistor george.n@l4b-software.com wrote:
Yes For one job to build tradefederation from inside a docker container. For the second job to run Google TradeFederation from the docker container.
Would be that possible with Lava?
george
-----Original Message----- From: Milosz Wasilewski milosz.wasilewski@linaro.org Sent: Thursday, August 8, 2019 1:16 PM To: George Nistor george.n@l4b-software.com Cc: lava-users@lists.lavasoftware.org Subject: Re: [Lava-users] running commands locally from a Lava job
George,
Do I understand correctly you would like to use LAVA as a building tool?
milosz
On Thu, 8 Aug 2019 at 10:47, George Nistor george.n@l4b-software.com wrote:
Hi Lava users,
Is it possible to run commands inside a lava job test-section, locally, from a Lava Job?
Ex:
cd /media/sh_shared_folders
docker build -t tradefed .
We have the following setup:
A machine with Linux Ubuntu; an Oracle Virtual Box VM on the machine with a Xubuntu distro image inside the VM we have created 3 Docker containers:
one with the Jenkins second one with Lava third is created for the purpose of running Google TradeFederation against the Android device
(The AOSP source tree is available to the VM via shared_folders and the docker container has also access to it. (via docker run -v dir_host:dir_container) )
What we what to achieve is to have 2 jobs in Lava :
one for building the Docker image for the purpose of building TradeFederation inside
Ex. Running these commande locally: source
./build/make/envsetup.sh
lunch
<device-target>
make
tradefed-all -j8
second using the above image, instantiate, create a container which should run TradeFederation against the android device connected to the machine
What I need is to be able to run commands locally inside the VM (on Xubuntu distro) from a Lava job. For these we have to somehow not send the command to qemu but run them locally.
Is this possible? If yes, how can we achieve this?
George Nistor
Lava-users mailing list Lava-users@lists.lavasoftware.org https://lists.lavasoftware.org/mailman/listinfo/lava-users
Lava-users mailing list Lava-users@lists.lavasoftware.org https://lists.lavasoftware.org/mailman/listinfo/lava-users
lava-users@lists.lavasoftware.org