From 080c5a4ea7367ad4811ac3dd88dfe3edba30f457 Mon Sep 17 00:00:00 2001 From: Dimitri Saridakis Date: Wed, 8 Nov 2023 16:37:26 +0000 Subject: [PATCH] refactor: use digest instead of tag for raycluster image --- src/codeflare_sdk/cluster/config.py | 2 +- tests/unit_test.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/codeflare_sdk/cluster/config.py b/src/codeflare_sdk/cluster/config.py index 192097646..b16cfd0f7 100644 --- a/src/codeflare_sdk/cluster/config.py +++ b/src/codeflare_sdk/cluster/config.py @@ -48,7 +48,7 @@ class ClusterConfiguration: instascale: bool = False mcad: bool = True envs: dict = field(default_factory=dict) - image: str = "quay.io/project-codeflare/ray:latest-py39-cu118" + image: str = "quay.io/project-codeflare/ray@sha256:1ddf39c1bbb182bc9f9c477fa0003902506013f8721f7e203673f965156f5559" local_interactive: bool = False image_pull_secrets: list = field(default_factory=list) dispatch_priority: str = None diff --git a/tests/unit_test.py b/tests/unit_test.py index c6b577365..2de0937b7 100644 --- a/tests/unit_test.py +++ b/tests/unit_test.py @@ -242,7 +242,10 @@ def test_config_creation(): assert config.min_cpus == 3 and config.max_cpus == 4 assert config.min_memory == 5 and config.max_memory == 6 assert config.num_gpus == 7 - assert config.image == "quay.io/project-codeflare/ray:latest-py39-cu118" + assert ( + config.image + == "quay.io/project-codeflare/ray@sha256:1ddf39c1bbb182bc9f9c477fa0003902506013f8721f7e203673f965156f5559" + ) assert config.template == f"{parent}/src/codeflare_sdk/templates/base-template.yaml" assert config.instascale assert config.machine_types == ["cpu.small", "gpu.large"]