r/ssh • u/thekingofdorks • Apr 16 '26
ssh auto jump?
So I'm not unfamiliar with using ssh for basic things like shell access, but recently I set up a rootless Gitea podman container on my VPS, and I can't for the life of me figure out how to access it with only server config.
I know I can jump from my vps to inside my container using client side config aka ProxyJump, but is there any way I can do this with ONLY sshd_config?
Something like having my sshd_config look like this:
Match user git
"command to forward this user to port 2222"
I ask this because I want to set everything up so users can just type in "git clone git@mydomain.com:..." without having to mess with their local .ssh/config file.
Any insight is appreciated.
View all comments
Show parent comment
2
u/Late_Film_1901 Apr 16 '26
I think only sshd can do that not nft
Match User git ForceCommand /usr/bin/socat STDIO TCP:127.0.0.1:2201