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

fix(main): fix: skip pulling app image #3649

Merged
merged 1 commit into from Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkg/apply/processor/interface.go
Expand Up @@ -191,7 +191,7 @@ func MountClusterImages(bdah buildah.Interface, cluster *v2.Cluster, skipApp boo
hasRootfsType = true
}
}
if imageType != "" && imageType != string(v2.RootfsImage) && imageType != string(v2.PatchImage) && skipApp {
if (imageType == "" || imageType == string(v2.AppImage)) && skipApp {
// then it's an application type image
continue
}
Expand Down
8 changes: 4 additions & 4 deletions pkg/apply/processor/scale.go
Expand Up @@ -162,11 +162,11 @@ func (c *ScaleProcessor) preProcess(cluster *v2.Cluster) error {
if err != nil {
return err
}
// cluster status might be overwrite by inappropriate usage, add mounts if loss.
if err = MountClusterImages(c.Buildah, cluster, true); err != nil {
return err
}
if c.IsScaleUp {
// cluster status might be overwrite by inappropriate usage, add mounts if loss.
if err = MountClusterImages(c.Buildah, cluster, true); err != nil {
return err
}
if cluster.GetRootfsImage().KubeVersion() == "" {
return fmt.Errorf("rootfs image not found kube version")
}
Expand Down