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

Add script to preload images onto nodes #8898

Merged
merged 2 commits into from
Mar 21, 2022
Merged

Add script to preload images onto nodes #8898

merged 2 commits into from
Mar 21, 2022

Conversation

meysholdt
Copy link
Member

Description

This PR adds a script that preloads the VM image onto all harvester nodes by creating a VM on every node.

Related Issue(s)

Fixes # #8634

How to test

Run ./dev/preview/distribute-images.sh -i image-xcx77 -s longhorn-image-xcx77-onereplica
See VMs getting created.

Release Notes

NONE

Documentation

Comment on lines 15 to 17

NODES=$(kubectl get nodes -o=jsonpath='{.items[*].metadata.name}')
NAMESPACE="distribute-${IMAGEID}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
NODES=$(kubectl get nodes -o=jsonpath='{.items[*].metadata.name}')
NAMESPACE="distribute-${IMAGEID}"
// We don't delete the namespace "distribute-${IMAGEID} because we want to avoid
// images from being garbage collected
NODES=$(kubectl get nodes -o=jsonpath='{.items[*].metadata.name}')
NAMESPACE="distribute-${IMAGEID}"
Suggested change
NODES=$(kubectl get nodes -o=jsonpath='{.items[*].metadata.name}')
NAMESPACE="distribute-${IMAGEID}"
NODES=$(kubectl get nodes -o=jsonpath='{.items[*].metadata.name}')
NAMESPACE="distribute-${IMAGEID}"

@roboquat roboquat merged commit 9bb0d12 into main Mar 21, 2022
@roboquat roboquat deleted the me/distributeimage branch March 21, 2022 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants