Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document how to load image to local cluster #8279

Open
ericzzzzzzz opened this issue Dec 22, 2022 · 1 comment
Open

Document how to load image to local cluster #8279

ericzzzzzzz opened this issue Dec 22, 2022 · 1 comment
Labels
area/docs kind/documentation priority/p2 May take a couple of releases triage/discuss Items for discussion

Comments

@ericzzzzzzz
Copy link
Contributor

ericzzzzzzz commented Dec 22, 2022

Background

  • some local kubernetes clusters cannot access images on local docker deamon directly, if the clusters want to use those images, those images are needed to load to the clusters.
  • Skaffold does images loading for some clusters under the hood, like minikube(by using the docker inside minikube), Kind, K3D, but Skaffold are not doing image loading work for other local clusters like micro8s
  • If images built by local docker daemon are not loaded to local clusters, deployment phase will fail, normally the uses will see images cannot be pull error
  • As a workaround, skaffold users can config build hooks for their build to load images
  • Note that the build hooks are able to access build output https://skaffold.dev/docs/pipeline-stages/lifecycle-hooks/#environment-variables
    example config for the workaround
apiVersion: skaffold/v4beta1
kind: Config
build:
  artifacts:
  - image: skaffold-example
    hooks:
      after:
        - command:
            - "bash"
            - "-c"
            - "xxx xxx xxx $SKAFFOLD_IMAGE"
  • We should document this
@ericzzzzzzz
Copy link
Contributor Author

Maybe skaffold should support creating a local registry with a container runtime? Then anything local cluster should just be able to pull images from the local registry, no more manual loading needed.

@ericzzzzzzz ericzzzzzzz added the triage/discuss Items for discussion label Aug 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/docs kind/documentation priority/p2 May take a couple of releases triage/discuss Items for discussion
Projects
None yet
Development

No branches or pull requests

2 participants