Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Discussion options

You must be logged in to vote

Ok, that's not a problem.

We can revisit your original message:

parsing flags ([gitssh -p 2222 git@server]) for "coder gitssh": unknown shorthand flag: 'p' in -p

The coder gitssh command WILL honor the --

After adding the ssh key to the remote host's .ssh/authenticated_keys, this should work:

coder gitssh -- -p $remote_port $remote_user@$remote_hsot

I have just tested after running coder gitssh:

...
Coder authenticates with  git  using the public
key below. All clones with SSH are authenticated automatically πŸͺ„.

 ssh-ed25519 AAA...
...

Added the key to the remote .ssh/authenticated_keys

Then

coder gitssh -- -p...
...
Are you sure you want to continue connecting (yes/no/[fingerprint])? …

Replies: 10 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by matifali
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Area: CLI
3 participants
Converted from issue

This discussion was converted from issue #19276 on August 11, 2025 11:52.