Show HN: I made an SSH tunnel manager to learn Go
61–70 of 72 posts
Re: Show HN: I made an SSH tunnel manager to learn Go
#62Well done. The ease of use and high quality of the Go SSH libraries (golang.org/x/crypto/ssh) is a killer feature of Go, imho. Also, there is a high level abstraction, github.com/gliderlabs/ssh, which makes it completely trivial to embed an ssh server into an application, giving you a nice way to inspect counters and flip feature flags and tuneables.
Re: Show HN: I made an SSH tunnel manager to learn Go
#63Re: Show HN: I made an SSH tunnel manager to learn Go
#64Earlier quoted context omitted.
XDG = X (pronounced “cross”) Desktop Group, aka freedesktop.org, promulgator of conventions for desktop apps. So, neither one really.
Yeah, I'm gonna stick with POSIX. All systems I'm aware of (other than Linux Desktop apps) use $HOME. If you want to extend your functionality to use an OS-specific directory, that's fine, but $HOME is the safest default. (Same for things like $TMPDIR)
Re: Show HN: I made an SSH tunnel manager to learn Go
#65After having spent the last year writing rust, it's a breath of fresh air to clone and read through a concise and straightforward repo like this.
Antiquated and verbose error handling model. The reliance on code generation because of the lack of a decent type system. The fact you have to carefully read through every function because it's not immutable by default, has pointer arguments and no functional operations e.g. filter.
It's a language that belongs back in the 1990s.
Re: Show HN: I made an SSH tunnel manager to learn Go
#66After having spent the last year writing rust, it's a breath of fresh air to clone and read through a concise and straightforward repo like this.
Is Rust still that hard to grok even after a year to you? This is by no means meant to be disrespectful but I'm itching to start learning Rust but having only worked in Python/C#/Go I'm getting cold feet just looking at a Rust codebase Disclaimer: I'm usually very good at hitting the ground running, but I am just as much bad at "keeping the pace", i.e. diving deep into stuff
One resource I would highly recommend after the basic stuff people always recommend is a book called "Learn Rust With Entirely Too Many Linked Lists".
Re: Show HN: I made an SSH tunnel manager to learn Go
#67Otherwise it looks good, great job !
Re: Show HN: I made an SSH tunnel manager to learn Go
#68If you don't mind a few small advices: don't use global variables that you mutate, prefer structs with methods. Add a main context with signal.NotifyContext to globally handle sigkill/sigterm and have a gracefull shutdown. Also use DialContext when available instead of Dial. You could use errGroup to handle multiple goroutines that return errors (rather than iterating on a channel). Otherwise it looks good, great job…
Re: Show HN: I made an SSH tunnel manager to learn Go
#69So what do you think of Go after the project? What language(s) did you come from?
Re: Show HN: I made an SSH tunnel manager to learn Go
#70Well done. The ease of use and high quality of the Go SSH libraries (golang.org/x/crypto/ssh) is a killer feature of Go, imho. Also, there is a high level abstraction, github.com/gliderlabs/ssh, which makes it completely trivial to embed an ssh server into an application, giving you a nice way to inspect counters and flip feature flags and tuneables.
How is performance? We found the native Go SSL libraries (as used in, e.g. the http package natively) to add many ms to web api calls. We eventually substituted OpenSSL (despite not really wanting to). It significantly sped up the app. YMMV, this is for ARM 32-bit targets.
If you're having performance issues with TLS I would look at what sort of crypto you're using. At least for SSH, RSA is dog slow. It wouldn't surprise me if you can irk out quite a bit of performance by switching to ed25519.