From 8218c0df280377fb6cc925eaceebe5fc67e3390a Mon Sep 17 00:00:00 2001 From: Romil Bhardwaj Date: Wed, 25 Sep 2024 18:28:28 -0700 Subject: [PATCH 1/2] Clarify k8s private registry auth in docs. --- docs/source/examples/docker-containers.rst | 8 ++++++++ .../reference/kubernetes/kubernetes-getting-started.rst | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/docs/source/examples/docker-containers.rst b/docs/source/examples/docker-containers.rst index 408a53a6185..d1e9854882b 100644 --- a/docs/source/examples/docker-containers.rst +++ b/docs/source/examples/docker-containers.rst @@ -18,6 +18,10 @@ SkyPilot can run a container either as a task, or as the runtime environment of Running Containers as Tasks --------------------------- +.. note:: + + On Kubernetes, running docker runtime in a pod is not recommended. Instead, :ref:`use your container as a runtime environment `. + SkyPilot can run containerized applications directly as regular tasks. The default VM images provided by SkyPilot already have the Docker runtime pre-configured. To launch a containerized application, you can directly invoke :code:`docker run` in the :code:`run` section of your task. @@ -173,6 +177,10 @@ Any GPUs assigned to the task will be automatically mapped to your Docker contai Private Registries ^^^^^^^^^^^^^^^^^^ +.. note:: + + These instructions do not apply to Kubernetes clusters. See :ref:`Using Images from Private Repositories in Kubernetes` for more. + When using this mode, to access Docker images hosted on private registries, you can provide the registry authentication details using :ref:`task environment variables `: diff --git a/docs/source/reference/kubernetes/kubernetes-getting-started.rst b/docs/source/reference/kubernetes/kubernetes-getting-started.rst index 51d8bf57565..4f87c8a6ee7 100644 --- a/docs/source/reference/kubernetes/kubernetes-getting-started.rst +++ b/docs/source/reference/kubernetes/kubernetes-getting-started.rst @@ -119,6 +119,8 @@ Once your cluster administrator has :ref:`setup a Kubernetes cluster `_ for more. +.. _kubernetes-custom-images-private-repos: + Using Images from Private Repositories ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ To use images from private repositories (e.g., Private DockerHub, Amazon ECR, Google Container Registry), create a `secret `_ in your Kubernetes cluster and edit your :code:`~/.sky/config.yaml` to specify the secret like so: From e626438aa2f14815f643b5c0b5c4eae7421673cf Mon Sep 17 00:00:00 2001 From: Romil Bhardwaj Date: Thu, 26 Sep 2024 08:39:53 -0700 Subject: [PATCH 2/2] comments --- docs/source/examples/docker-containers.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/source/examples/docker-containers.rst b/docs/source/examples/docker-containers.rst index d1e9854882b..41a5e13a027 100644 --- a/docs/source/examples/docker-containers.rst +++ b/docs/source/examples/docker-containers.rst @@ -20,7 +20,7 @@ Running Containers as Tasks .. note:: - On Kubernetes, running docker runtime in a pod is not recommended. Instead, :ref:`use your container as a runtime environment `. + On Kubernetes, running Docker runtime in a pod is not recommended. Instead, :ref:`use your container as a runtime environment `. SkyPilot can run containerized applications directly as regular tasks. The default VM images provided by SkyPilot already have the Docker runtime pre-configured. @@ -179,7 +179,7 @@ Private Registries .. note:: - These instructions do not apply to Kubernetes clusters. See :ref:`Using Images from Private Repositories in Kubernetes` for more. + These instructions do not apply if you use SkyPilot to launch on Kubernetes clusters. Instead, see :ref:`Using Images from Private Repositories in Kubernetes` for more. When using this mode, to access Docker images hosted on private registries, you can provide the registry authentication details using :ref:`task environment variables `: