Skip to content

Commit 537b322

Browse files
committed
use nextflow base image when generating default dockerfile
1 parent 66920c3 commit 537b322

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

src/latch_cli/docker_utils/__init__.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,11 @@
99
import yaml
1010

1111
from latch_cli.utils import WorkflowType
12-
from latch_cli.workflow_config import LatchWorkflowConfig, get_or_create_workflow_config
12+
from latch_cli.workflow_config import (
13+
BaseImageOptions,
14+
LatchWorkflowConfig,
15+
get_or_create_workflow_config,
16+
)
1317

1418

1519
class DockerCmdBlockOrder(str, Enum):
@@ -424,8 +428,12 @@ def generate_dockerignore(
424428
def get_default_dockerfile(pkg_root: Path, *, wf_type: WorkflowType):
425429
default_dockerfile = pkg_root / "Dockerfile"
426430

427-
# shitty: assumption that config is already there so base image will be ignored
428-
config = get_or_create_workflow_config(pkg_root=pkg_root)
431+
config = get_or_create_workflow_config(
432+
pkg_root=pkg_root,
433+
base_image_type=BaseImageOptions.nextflow
434+
if wf_type == WorkflowType.nextflow
435+
else BaseImageOptions.default,
436+
)
429437

430438
if not default_dockerfile.exists():
431439
default_dockerfile = pkg_root / ".latch" / "Dockerfile"

0 commit comments

Comments
 (0)