Last active
December 15, 2023 07:18
-
-
Save fabiand/ce62b4850685bce57c29c43ea95abf9e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# virtctl is in your $PATH | |
# You are logged into a cluster | |
# Then the snippet below enables seamless ssh login. | |
# Usage `ssh [<user>@]<vmname>.<namespace>.ocp` | |
# "ocp" can be anything, for convenience replace with your cluster's base fqdn | |
host *.ocp | |
ProxyCommand virtctl port-forward --stdio=true %h %p |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It could be nice if
virtctl ssh
could also read stdin/stdout so this configuration could be more obvious. eg.Even better if stdio=true was the default.
Right now this works
tar cf - files | virtctl ssh cloud-user@vm -c 'tar xf -'
, but it would be wonderful ifvirtctl ssh
behaved more likessh
and the-c
could be omitted.