41-Import Harvester into nested Rancher

Prerequisite: External network on VLAN

  1. Install Rancher in a VM using Docker method on Harvester cluster using the external VLAN
  2. Login rancher dashboard
  3. Navigate to Virtual Management Page
  4. Click import existing
  5. Copy the curl command image.png
  6. SSH to harvester master node (user: rancher)
  7. Execute the curl command to import harvester to rancher curl --insecure -sfL https://192.168.50.82/v3/import/{identifier}.yaml | kubectl apply -f -
  8. Run sudo chmod 775 /etc/rancher/rke2/rke2.yaml to solve the permission denied error
  9. Run curl command again, you should see the following successful import message
    namespace/cattle-system configured
    serviceaccount/cattle created
    clusterrolebinding.rbac.authorization.k8s.io/cattle-admin-binding created
    secret/cattle-credentials-413137f created
    clusterrole.rbac.authorization.k8s.io/cattle-admin created
    deployment.apps/cattle-cluster-agent created
    service/cattle-cluster-agent created
    
  10. Check import status in Virtualization Management page on Rancher

Expected Results

  1. Harvester successfully imported on virtualization management page image.png
  2. Can access Harvester from Rancher dashboard
  3. Display Project/Namespaces and RBAC tab image.png