From c51ab98d85deea2893b898cfb9f31fc8790b588e Mon Sep 17 00:00:00 2001 From: Bobbins228 Date: Mon, 10 Jun 2024 11:39:31 +0100 Subject: [PATCH] Replaced old ray image with new 2.20.0 image --- src/codeflare_sdk/templates/base-template.yaml | 4 ++-- tests/e2e/support.py | 2 +- tests/test-case-bad.yaml | 4 ++-- tests/test-case-no-mcad.yamls | 4 ++-- tests/test-case.yaml | 4 ++-- tests/test-default-appwrapper.yaml | 4 ++-- tests/unit-test-volume-cluster.yaml | 6 +++--- tests/unit_test.py | 18 +++++++++--------- tests/unit_test_support.py | 2 +- 9 files changed, 24 insertions(+), 24 deletions(-) diff --git a/src/codeflare_sdk/templates/base-template.yaml b/src/codeflare_sdk/templates/base-template.yaml index 07ab41046..5c0c919d5 100644 --- a/src/codeflare_sdk/templates/base-template.yaml +++ b/src/codeflare_sdk/templates/base-template.yaml @@ -69,7 +69,7 @@ spec: containers: # The Ray head pod - name: ray-head - image: quay.io/project-codeflare/ray:latest-py39-cu118 + image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 imagePullPolicy: Always ports: - containerPort: 6379 @@ -152,7 +152,7 @@ spec: spec: containers: - name: machine-learning # must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character (e.g. 'my-name', or '123-abc' - image: quay.io/project-codeflare/ray:latest-py39-cu118 + image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 # environment variables to set in the container.Optional. # Refer to https://kubernetes.io/docs/tasks/inject-data-application/define-environment-variable-container/ lifecycle: diff --git a/tests/e2e/support.py b/tests/e2e/support.py index a3dfd89bd..04c9cb421 100644 --- a/tests/e2e/support.py +++ b/tests/e2e/support.py @@ -8,7 +8,7 @@ def get_ray_image(): - default_ray_image = "quay.io/project-codeflare/ray:latest-py39-cu118" + default_ray_image = "quay.io/project-codeflare/ray:2.20.0-py39-cu118" return os.getenv("RAY_IMAGE", default_ray_image) diff --git a/tests/test-case-bad.yaml b/tests/test-case-bad.yaml index b90cdeb1a..18dcb7d71 100644 --- a/tests/test-case-bad.yaml +++ b/tests/test-case-bad.yaml @@ -42,7 +42,7 @@ spec: valueFrom: fieldRef: fieldPath: status.podIP - image: quay.io/project-codeflare/ray:latest-py39-cu118 + image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 imagePullPolicy: Always lifecycle: preStop: @@ -90,7 +90,7 @@ spec: valueFrom: fieldRef: fieldPath: status.podIP - image: quay.io/project-codeflare/ray:latest-py39-cu118 + image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 lifecycle: preStop: exec: diff --git a/tests/test-case-no-mcad.yamls b/tests/test-case-no-mcad.yamls index b3916c81e..d8d2516c5 100644 --- a/tests/test-case-no-mcad.yamls +++ b/tests/test-case-no-mcad.yamls @@ -33,7 +33,7 @@ spec: template: spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 imagePullPolicy: Always lifecycle: preStop: @@ -106,7 +106,7 @@ spec: key: value spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 lifecycle: preStop: exec: diff --git a/tests/test-case.yaml b/tests/test-case.yaml index 4fd1edcc1..c5229ce79 100644 --- a/tests/test-case.yaml +++ b/tests/test-case.yaml @@ -38,7 +38,7 @@ spec: template: spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 imagePullPolicy: Always lifecycle: preStop: @@ -111,7 +111,7 @@ spec: key: value spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 lifecycle: preStop: exec: diff --git a/tests/test-default-appwrapper.yaml b/tests/test-default-appwrapper.yaml index f2e8a39e5..8fd1873f1 100644 --- a/tests/test-default-appwrapper.yaml +++ b/tests/test-default-appwrapper.yaml @@ -38,7 +38,7 @@ spec: template: spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 imagePullPolicy: Always lifecycle: preStop: @@ -110,7 +110,7 @@ spec: key: value spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 lifecycle: preStop: exec: diff --git a/tests/unit-test-volume-cluster.yaml b/tests/unit-test-volume-cluster.yaml index 542f11833..67d2c6b25 100644 --- a/tests/unit-test-volume-cluster.yaml +++ b/tests/unit-test-volume-cluster.yaml @@ -29,7 +29,7 @@ spec: template: spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 imagePullPolicy: Always lifecycle: preStop: @@ -102,7 +102,7 @@ spec: - name: test3 secret: secretName: test-secret - rayVersion: 2.7.0 + rayVersion: 2.20.0 workerGroupSpecs: - groupName: small-group-unit-test-volume-cluster maxReplicas: 1 @@ -119,7 +119,7 @@ spec: key: value spec: containers: - - image: quay.io/project-codeflare/ray:latest-py39-cu118 + - image: quay.io/project-codeflare/ray:2.20.0-py39-cu118 lifecycle: preStop: exec: diff --git a/tests/unit_test.py b/tests/unit_test.py index a05872c4d..4b48b173c 100644 --- a/tests/unit_test.py +++ b/tests/unit_test.py @@ -261,7 +261,7 @@ def test_config_creation(): assert config.min_cpus == 3 and config.max_cpus == 4 assert config.min_memory == "5G" and config.max_memory == "6G" assert config.num_gpus == 7 - assert config.image == "quay.io/project-codeflare/ray:latest-py39-cu118" + assert config.image == "quay.io/project-codeflare/ray:2.20.0-py39-cu118" assert config.template == f"{parent}/src/codeflare_sdk/templates/base-template.yaml" assert config.machine_types == ["cpu.small", "gpu.large"] assert config.image_pull_secrets == ["unit-test-pull-secret"] @@ -400,7 +400,7 @@ def test_cluster_creation_no_mcad_local_queue(mocker): num_gpus=7, machine_types=["cpu.small", "gpu.large"], image_pull_secrets=["unit-test-pull-secret"], - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", write_to_file=True, appwrapper=False, local_queue="local-queue-default", @@ -428,7 +428,7 @@ def test_default_cluster_creation(mocker): ) default_config = ClusterConfiguration( name="unit-test-default-cluster", - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", appwrapper=True, ) cluster = Cluster(default_config) @@ -493,7 +493,7 @@ def test_cluster_with_custom_volumes(mocker): test_config = ClusterConfiguration( name="unit-test-volume-cluster", - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", volume_mounts=volume_mounts, volumes=volumes, ) @@ -839,7 +839,7 @@ def test_ray_job_wrapping(mocker): return_value=get_local_queue("kueue.x-k8s.io", "v1beta1", "ns", "localqueues"), ) cluster = cluster = createClusterWithConfig(mocker) - cluster.config.image = "quay.io/project-codeflare/ray:latest-py39-cu118" + cluster.config.image = "quay.io/project-codeflare/ray:2.20.0-py39-cu118" mocker.patch( "ray.job_submission.JobSubmissionClient._check_connection_and_version_with_url", return_value="None", @@ -959,7 +959,7 @@ def test_ray_details(mocker, capsys): ClusterConfiguration( name="raytest2", namespace="ns", - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", write_to_file=True, appwrapper=True, local_queue="local_default_queue", @@ -2352,7 +2352,7 @@ def test_cluster_status(mocker): ClusterConfiguration( name="test", namespace="ns", - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", write_to_file=True, appwrapper=True, local_queue="local_default_queue", @@ -2447,7 +2447,7 @@ def test_wait_ready(mocker, capsys): ClusterConfiguration( name="test", namespace="ns", - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", write_to_file=True, appwrapper=True, local_queue="local-queue-default", @@ -2674,7 +2674,7 @@ def throw_if_getting_raycluster(group, version, namespace, plural): cluster = Cluster( ClusterConfiguration( "test_cluster", - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", write_to_file=False, ) ) diff --git a/tests/unit_test_support.py b/tests/unit_test_support.py index baa14aaca..6e662db44 100644 --- a/tests/unit_test_support.py +++ b/tests/unit_test_support.py @@ -17,7 +17,7 @@ def createClusterConfig(): appwrapper=True, machine_types=["cpu.small", "gpu.large"], image_pull_secrets=["unit-test-pull-secret"], - image="quay.io/project-codeflare/ray:latest-py39-cu118", + image="quay.io/project-codeflare/ray:2.20.0-py39-cu118", write_to_file=True, ) return config