Due to limitations in the harbor registry, we cannot port forward to connect the harbor registry for local system. However, we can save the image and send it to jump server/remote server, and through the remote server we can upload the image to the harbor private registry.
Added below in ~/.ssh/config
Host base
User <user>
IdentityFile ~/.ssh/<private key>
HostName ip/hostid/hostname
ProxyCommand sh -c "aws ssm start-session --target %h --document-name AWS-StartSSHSession --parameters 'portNumber=%p' --profile <aws profile>"
Host doc-jump
User <user>
IdentityFile ~/.ssh/<private key>
HostName ip/hostid/hostname
ProxyCommand ssh -q -CW %h:%p base
docker tag cirros:latest <harbor externalurl>/test/cirros:latest
ssh doc-jump "docker load --input ~/doc-image/cirros.tar"
ssh doc-jump "docker images"
ssh doc-jump "docker push <harbor externalurl>/test/cirros:latest"