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

feat: add rancher integration for airgapped environment and prime case #694

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

FrankYang0529
Copy link
Member

No description provided.

Copy link

github-actions bot commented Dec 23, 2024

Name Link
🔨 Latest commit ec8b3ef
😎 Deploy Preview https://67adc565a0dfca63d748fe94--harvester-preview.netlify.app

@bk201
Copy link
Member

bk201 commented Dec 23, 2024

@FrankYang0529 is there an issue with the change?

## Work with prime Rancher

The prime Rancher uses different registry. If there is no `CATTLE_AGENT_IMAGE` environment variable, the default value uses `docker.io` as default registry whick makes the Harvester can't get correct rancher-agent image. You need to set the `CATTLE_AGENT_IMAGE` environment variable to the correct registry.
Copy link
Member

Choose a reason for hiding this comment

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

our doc doesn't suggest using the docker way to deploy Rancher, does Helm deployment need this?

Copy link
Member Author

Choose a reason for hiding this comment

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

@bk201 @jillian-maroket

Yeah, helm is not different from docker. We still need to provide CATTLE_AGENT_IMAGE.

We can add following arguments to helm install command.

--set 'extraEnv[0].name=CATTLE_AGENT_IMAGE' --set 'extraEnv[0].value=<registry>rancher/rancher-agent:v2.8.10'

ref: https://suse.slack.com/archives/C07DUPSJUPM/p1730990051021459?thread_ts=1730981591.009469&cid=C07DUPSJUPM

Copy link
Contributor

Choose a reason for hiding this comment

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

@FrankYang0529 Can you provide the exact code block for the Prime doc? Thank you.

Copy link
Member Author

Choose a reason for hiding this comment

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

Hi @jillian-maroket, I think it's better for users to follow Rancher document to install it. For full command, they can reference https://ranchermanager.docs.rancher.com/getting-started/quick-start-guides/deploy-rancher-manager/helm-cli. We may just mention to add arguments --set 'extraEnv[0].name=CATTLE_AGENT_IMAGE' --set 'extraEnv[0].value=<registry>rancher/rancher-agent:v2.8.10' to helm command to solve the issue.

Copy link
Contributor

@jillian-maroket jillian-maroket left a comment

Choose a reason for hiding this comment

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

I have reviewed the text. Please note that I will add the Prime-specific content to the SUSE Virtualization section of the Prime doc.

docs/airgap.md Outdated Show resolved Hide resolved
docs/airgap.md Outdated Show resolved Hide resolved
docs/airgap.md Outdated Show resolved Hide resolved
docs/airgap.md Outdated Show resolved Hide resolved
Comment on lines 165 to 172

The prime Rancher uses different registry. If there is no `CATTLE_AGENT_IMAGE` environment variable, the default value uses `docker.io` as default registry whick makes the Harvester can't get correct rancher-agent image. You need to set the `CATTLE_AGENT_IMAGE` environment variable to the correct registry.

Example:
```bash
docker run --privileged -d --name=rancher --restart=unless-stopped -p 8080:80 -p 6443:443 -e CATTLE_AGENT_IMAGE=<registry>/rancher/rancher-agent:v2.8.10 <registry>/rancher/rancher:v2.8.10
```
Copy link
Contributor

@jillian-maroket jillian-maroket Feb 11, 2025

Choose a reason for hiding this comment

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

Please remove this section. I will add it to the Prime doc. Here is the proposed text for Prime:

Rancher determines the rancher-agent image to be used whenever a Harvester cluster is imported. If the image is not included in the Harvester ISO, it must be pulled from the internet and loaded on each node, or pushed to the Harvester cluster's registry.

Rancher Prime uses a dedicated registry, so you must assign that registry as the value of the CATTLE_AGENT_IMAGE environment variable. If you do not assign a value, Harvester is unable to retrieve the correct rancher-agent image because docker.io is used as the default registry.

Example:

docker run --privileged -d --name=rancher --restart=unless-stopped -p 8080:80 -p 6443:443 -e CATTLE_AGENT_IMAGE=<registry>/rancher/rancher-agent:v2.8.10 <registry>/rancher/rancher:v2.8.10

@jillian-maroket
Copy link
Contributor

@FrankYang0529 and @bk201 I created this PR in the Prime docs repo. Our doc project manager is asking if this applies to Helm-based installations. Please help provide more context. I'm pasting the full review comment here in case you are unable to access the repo.

Is this requirement applicable to Helm-based installations as well? If so, the example should use Helm instead since Docker-based installations are not supported. We're trying to remove (and have already removed some) Docker-based installation references from our Product and Prime docs.

@bk201
Copy link
Member

bk201 commented Feb 13, 2025

@FrankYang0529 please check https://github.com/harvester/docs/pull/694/files#r1895396706 for helm installation

@FrankYang0529 FrankYang0529 force-pushed the airgapped-prime-rancher branch from 0d9510a to ea9114b Compare February 13, 2025 09:53
Co-authored-by: Jillian Maroket <[email protected]>
Signed-off-by: PoAn Yang <[email protected]>
@FrankYang0529 FrankYang0529 force-pushed the airgapped-prime-rancher branch from ea9114b to ec8b3ef Compare February 13, 2025 09:53
@FrankYang0529
Copy link
Member Author

@jillian-maroket thanks for the review and suggestion. I address all comments. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants