Commit 8ec70450 authored by Rémi Duraffort's avatar Rémi Duraffort

Merge branch 'docker-raise' into 'master'

docker: raise an exception when the deploy action is missing

See merge request !792
parents 1eafb4f1 4a1b0715
Pipeline #5920 passed with stages
in 9 minutes and 56 seconds
......@@ -20,6 +20,7 @@
import os
from lava_common.exceptions import JobError
from lava_dispatcher.action import Pipeline, Action
from lava_dispatcher.logical import Boot, RetryAction
from lava_dispatcher.actions.boot import BootAction
......@@ -96,6 +97,12 @@ class CallDockerAction(Action):
options = self.job.device["actions"]["boot"]["methods"]["docker"]["options"]
docker_image = self.get_namespace_data(
action="deploy-docker", label="image", key="name"
if docker_image is None:
raise JobError("Missing deploy action before boot")
if options["cpus"]:
self.extra_options += " --cpus %s" % options["cpus"]
if options["memory"]:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment