Coder SSH Not Respecting SendEnv & AcceptEnv?

On my local machine I have
# ~/.ssh/config
Host *
SendEnv INSIDE_EMACS
# ~/.ssh/config
Host *
SendEnv INSIDE_EMACS
And on my coder instance I have:
# /etc/ssh/ssh_config
Host *
AcceptEnv INSIDE_EMACS
# /etc/ssh/ssh_config
Host *
AcceptEnv INSIDE_EMACS
I restarted my computer and restarted the workspace instance. Inside my local terminal I run
export INSIDE_EMACS=y
coder ssh noah
export INSIDE_EMACS=y
coder ssh noah
Inside the remote terminal when I echo $INSIDE_EMACS the variable is empty. I know that Coder had a somewhat special SSH agent or something, is it possible that is interfering w the SSH env var setup?
13 Replies
Turtle Kayak
Turtle Kayak3y ago
When I run ssh coder.noah the env var gets set correctly
Cian
Cian3y ago
Is this in Coder OSS?
Turtle Kayak
Turtle Kayak3y ago
Yes
maf
maf3y ago
coder ssh is not as fully featured as ssh coder.. We don't parse ~/.ssh/config, for instance. If we would add support for sending env vars, it'd probably be coder ssh --env or something similar (perhaps ENV variable support as well).
Cian
Cian3y ago
That's a good point -- do you see this behaviour only with coder ssh, or do you see it with both ssh coder.XXX and coder ssh XXX ?
Turtle Kayak
Turtle Kayak3y ago
This behavior only happens when I use coder ssh . Using ssh coder... works correctly. On a similar note I'm seeing a lot of latency in remote development (access the server takes a while for file operations). I might try to expose an ssh port or make a vpn and just use raw SSH to see if the coder agent traffic forwarding is the cause.
Phorcys
Phorcys3y ago
yes, it's not the same thing coder ssh doesn't actually use the ssh config, bottom line is: use ssh coder.whatever doubt, it's pretty speedy for me but you could still check
Turtle Kayak
Turtle Kayak3y ago
Yea I am not so sure myself bc some ssh based remote dev solutions are fast and some are slow
Phorcys
Phorcys3y ago
@Turtle Kayak btw, you can use /resolve to close the thread when/if you're done
Turtle Kayak
Turtle Kayak3y ago
Oh cool thanks
Phorcys
Phorcys3y ago
except the bot is down for some reason i'll look into it
Turtle Kayak
Turtle Kayak3y ago
Lmao ofc Nw
Phorcys
Phorcys3y ago
should be good now
Want results from more Discord servers?
Add your server