The Joys Of Programming

I’m in the process of upgrading my home Linux server. It finally has enough hardware to be a halfway decent development server.

Currently any home development I do is in local PyCharm, VS Code, WSL, and Docker Desktop. I mostly don’t use devcontainers for my home development yet.

My plan is to try transitioning to the new VS Code Server running on the Linux server and only use a browser to connect and do work from client devices. Run everything inside devcontainers. Have nearly no devlopment tools installed directly on the server as I can have all that in containers these days.

While I wait for the new VS Code Server to mature I’m either running VS Code on the client side with remote development extensions to do all actual development in devcontainers on the Linux server or, when my client device is too thin, just Remote Desktop into the Linux server and use VS Code there. I’m syncing my VS Code configs so it’s not terrible having it installed in multiple places but I’m really looking forward to the day I only need a browser on the client device.

I’m still converting my personal projects to devcontainers so it’s a work in progress but the last couple years of devcontainers at work has convinced me I can get anything to work this way. Docker-in-Docker and Kubernetes-in-Docker. Moby. The tool chain has matured massively over the last few years.

Edit: I don’t do much development from outside my house right now but I’m playing around with tailscale a bit. Combining that with the new VS Code Server would be really slick. Just not something I need right now.

So far so good. Been developing on my dev server from a tablet/convertible and a desktop.

Converted my video syncing system over to Python and moved it into a container. It was mostly just shell scripts before. Using a dev container for this project now.

Ported my kids Minecraft servers over to Docker containers, setup another container to automate the world backups, and another that makes multiple servers on one host discoverable over the local network. Most of that was finding the right containers and getting my compose file right and not a lot of programming but I did contribute a small security fix back to one of the containers along the way.

Automating building all my own images locally as these Minecraft projects don't seem to re-build their images fast enough and there were lots of security fixes in the base image they were missing. Docker is great and all but every container adds yet another OS you have to worry about vulnerabilities on. Automation is a necessity here or I'd never stay on top of it. I'm in the process of automating image vuln scanning and alerting now as it's a little too manual the way I've been doing it. Hoping to leverage an existing project for a lot of that but if not I can whip up something based on Snyk (docker scan) if I have to.

I still need to get a subset of my backups mirroring to the cloud automatically. Losing my kids Minecraft worlds is not an option Whatever I do here I plan to also run in a container. Duplicati perhaps.

I've been developing software for over 30 years and I know the thing that keeps me learning is projects. I'm not usually motivated by cool technology itself, I'm motivated by solving problems. Sometimes I create those problems for myself

Edit: I have now done some basic dev work from my Steam Deck remoted into the dev server (with bluetooth keyboard). I used RDP instead of installing VSCode on the Deck as I don't really intend to develop from it again but, as Valve says, it's just a PC so of course I had to write some code from it. It would look pretty weird to my Steam friends to see me "playing" VSCode.

That sounds like fun. My first touch with Linux was in 1994 when I started installing it on Comp Sci lab computers for one of my professors in college. After college I almost solely used Linux from 1998 up until 2008 when I got my first OS X Mac and made the switch over to that. Since then I haven't touched Linux much.

In my day, though, I was pretty handy with it. At one point in 1999 I had a Linux server setup that had a modem that would dial up to the 56k connection if anyone tried to make a connection through the Linux server. I set it up as a router, basically, using the wireless protocol available those days (1 mbps). I would put PCMCIA cards in devices like an HP Jornada Windows CE device and use that wirelessly through my Linux server from my couch.

That was back when you had to manually create routing tables and that kind of nonsense. I assume it's easier now. I remember even having to adjust the source code for the wireless card driver in the Linux server and recompile it.

Anyway, point is I understand the joy of learning by doing and Linux being one of the most fun playgrounds. You have me thinking now about whether I should setup a dev server in my house. Knowing how my brain works, though, I'd try to just get it going in AWS instead to force myself to learn AWS better.

I started playing around with neovim last week. Mostly a smooth transition from regular vim, and the terminal mode is neat.

DSGamer wrote:

That sounds like fun. My first touch with Linux was in 1994 when I started installing it on Comp Sci lab computers for one of my professors in college. After college I almost solely used Linux from 1998 up until 2008 when I got my first OS X Mac and made the switch over to that. Since then I haven't touched Linux much.

In my day, though, I was pretty handy with it. At one point in 1999 I had a Linux server setup that had a modem that would dial up to the 56k connection if anyone tried to make a connection through the Linux server. I set it up as a router, basically, using the wireless protocol available those days (1 mbps). I would put PCMCIA cards in devices like an HP Jornada Windows CE device and use that wirelessly through my Linux server from my couch.

That was back when you had to manually create routing tables and that kind of nonsense. I assume it's easier now. I remember even having to adjust the source code for the wireless card driver in the Linux server and recompile it.

Anyway, point is I understand the joy of learning by doing and Linux being one of the most fun playgrounds. You have me thinking now about whether I should setup a dev server in my house. Knowing how my brain works, though, I'd try to just get it going in AWS instead to force myself to learn AWS better.

Nice! The good old days.

I played around with Red Hat in the mid 90s. My University used Solaris and Debian mostly but I dabbled in a bit of everything. Distro hopping regularly. Trying BeOS, QNX, BSD, and various Linux distros before eventually settling on Slackware and sticking with that for years. (Unfortunately) I've compiled my share of kernels and modules over the years

After University I worked at a Mac only company for a bit and they refused to let us use anything but Apple hardware/OS even on the servers. Outside that experience I've been using Linux in some way for work and at home the whole time. I haven't really used desktop Linux for years but then I got my Steam Deck and have been getting back into it a bit.

I know some people who host their dev servers on an Azure VM and are very happy with it. AWS would be basically the same. I've been curious to try something like GitHub Codespaces one day. For my current dev server I knew I was going to be running a bunch of local services like Plex and Minecraft servers so I figured I'd throw my dev server on the local hardware as well.

Makes sense. I remember the days of distro-hopping fondly as well. I think altogether I tried Red Hat, SuSE, Fedora, CentOS, Ubuntu, Mandrake, Debian and FreeBSD.

My favorite in all that time as an end user was probably SuSE before Oracle purchased them. It was a very professional distro that made a lot of sense to me at the time. Eventually I would settle on Ubuntu once that became fairly ubiquitous and I was done toying around as much.

What’s your current system run?

DSGamer wrote:

Makes sense. I remember the days of distro-hopping fondly as well. I think altogether I tried Red Hat, SuSE, Fedora, CentOS, Ubuntu, Mandrake, Debian and FreeBSD.

My favorite in all that time as an end user was probably SuSE before Oracle purchased them. It was a very professional distro that made a lot of sense to me at the time. Eventually I would settle on Ubuntu once that became fairly ubiquitous and I was done toying around as much.

What’s your current system run?

Kubuntu LTS.

Spoiler:

I used SuSE for a bit right before I switched to Slackware. After Slackware I switched to Ubuntu mostly because it was easier to get the hardware on my laptop working properly. Slackware was sometimes frustrating to get everything working. I've been mostly using flavors of Ubu since. I've used various other server distros for work.

I was tempted to try an Arch based distro on my dev server after my experience with the Deck (SteamOS is based on Arch) but figured I'd just go with what I'm really comfortable with so Ubu based it is. I ended up using Kubuntu LTS mostly because I'd been using KDE on the Deck and figured I'd stick with that on the dev server as well.

I typically use PuTTY to ssh into the Linux servers running on my ESXI host here and if I want to run the GUI on one of the servers, I do it in the console on the VMWare web management tool.

I need 2 recommendations for free tools (for Windows 10 and above):

1) A ssh command-line tool like PuTTY that has multiple tabs for more sessions.
2) An x-server or some other way to connect to the servers with a GUI frontend.

The flavors I currently have running are Ubuntu and Mint.

What do you guys suggest?

-BEP

I don't use a tabbed PuTTY-like, per se, but I do have one option that fits both of those requirements, and is something that I use as one of my fundamental tools at work, every day, almost exclusively:

X2Go client running on my local Windows laptop, connecting to an X2Go server running on my remote VM, which starts an X11 Terminator instance. From the Terminator window I can then open multiple tabs (ctrl-shift-t), or split the current tab into multiple panes either horizontally (ctrl-shift-o) or vertically (ctrl-shift-e). Each pane/tab gets its own local shell instance on the VM, and from each of those, I can ssh out to whatever other remote server I want. I can also invoke other X11 apps on my VM and they pop open as new windows on my local Windows laptop.

Also, if I lose my connection between X2Go client and server (e.g. if I reboot my local PC, or network connection drops, or whatever), the Terminator instance continues running on my VM, and I can just restart the X2Go client and re-attach. Extremely convenient when I have a dozen tabs open, each with SSHs out to remote servers doing long-running activities; if that was a regular PuTTY, those remote shells would've likely died when the network connection dropped.

X11 is normally a VERY bandwidth-intensive, latency-bothered protocol, but X2Go does some amazing magic that makes it actually an extremely pleasant experience: It creates a virtualized Display on the VM server, so it's not sending any X11 commands or bitmaps across the network; instead, it sends a compressed mpeg stream (or h264 or whatever), and somehow it all just works and makes the Terminator feel like a regular Windows process. It does take a fair bit of setup and brain-adjustment, and it occasionally does get wonky (particularly when copy/pasting between a Windows app and the Terminator), but it's otherwise a beautiful setup, imho.

Edit: Actually, now that I think about it, the wonky copy/paste behavior I think was more related to me running gvim alongside Terminator, and the copy/paste got wonky when using both gvim's clipboard as well as the Windows clipboard and the X11 native clipboard for Terminator. I stopped using gvim a year or two back, and switched to using VSCode natively on Windows, remote-connecting it to my VM. I can't remember the last time I had a clipboard issue with this setup.

bepnewt wrote:

I typically use PuTTY to ssh into the Linux servers running on my ESXI host here and if I want to run the GUI on one of the servers, I do it in the console on the VMWare web management tool.

I need 2 recommendations for free tools (for Windows 10 and above):

1) A ssh command-line tool like PuTTY that has multiple tabs for more sessions.
2) An x-server or some other way to connect to the servers with a GUI frontend.

The flavors I currently have running are Ubuntu and Mint.

What do you guys suggest?

-BEP

1) There is always MTPuTTY but TBH these days I just use the newish Windows Terminal and the OpenSSH that comes with Windows instead of PuTTY. Has an ssh agent and uses OpenSSH keys instead of PuTTY ones. Windows Terminal supports tabs/etc. If you are comfortable with PuTTY then MTPuTTY will be comfortable too.
2) maybe VcXsrv Windows X Server. I haven't used an X server in Windows for years so I have no recent experience to share.

For my current stuff I just installed xrdp on the server as I've been using RDP for most of my graphical remote machine management for a while so it was comfortable and it's an efficient enough protocol. Anything I don't need a GUI for I just use OpenSSH or a shell through VSCode.

bepnewt wrote:

I typically use PuTTY to ssh into the Linux servers running on my ESXI host here and if I want to run the GUI on one of the servers, I do it in the console on the VMWare web management tool.

I need 2 recommendations for free tools (for Windows 10 and above):

1) A ssh command-line tool like PuTTY that has multiple tabs for more sessions.
2) An x-server or some other way to connect to the servers with a GUI frontend.

The flavors I currently have running are Ubuntu and Mint.

What do you guys suggest?

-BEP

WSL claims to be able to do that out of the box, with the Terminal supporting multiple tabs, hosting WSL, Powershell, and cmd sessions in any combination.

Thanks for all the suggestions, folks. xrdp solves both issues.

I shoulda guessed there was something like that out there that worked with RDP, but I didn't. The last time I ran X from my PC, I was connecting to Perisparcs back in 2000.

'Course, I downloaded the source then starting building it before it occurred to me to see if it was already a package that I could install. Sure enough...

Thanks again.
-BEP

Mixolyde wrote:

I started playing around with neovim last week. Mostly a smooth transition from regular vim, and the terminal mode is neat.

Neovim IS Vim as far as I'm concerned.

Vim wouldn't have any of its newer features if not for Neovim forcing the issue. It's a much better run, forward moving project.

*Legion* wrote:
Mixolyde wrote:

I started playing around with neovim last week. Mostly a smooth transition from regular vim, and the terminal mode is neat.

Neovim IS Vim as far as I'm concerned.

Vim wouldn't have any of its newer features if not for Neovim forcing the issue. It's a much better run, forward moving project.

Yeah, that's the impression I'm getting, too. It's pretty nice. I haven't dug into plugins much yet because I don't do as much coding as I used to. Mostly just editing configuration files and notes files. But I think ctags would probably be a big help.

The plugin system is nice, because Neovim has Lua embedded, so the plugin ecosystem has coalesced around Lua (even though you can do plugins in other languages).

Vim continues to fight tooth and nail to keep vimscript being a thing, leading to vim9script.

This is the pattern with Neovim and Vim. Neovim makes an important change to the Vim concept, Vim comes in behind them with a version that's different for the sake of being different (severe NIH syndrome) and minimal acknowledgement that Neovim's the one who broke the ground.

There feels like a lot of vanity is behind the Vim project. Neovim feels like a community project.

I think the most useful thing I ever learned about VI and Emacs was how to get out of them so I could use something else:
escape : q ! enter and ctrl-x ctrl-c

just kidding please don’t kill me in the ensuing flame war.

You’re not alone. Even back when I was full time on Linux I found the command line editors frustrating so I just used nano. I begrudgingly learned emacs and grew to like it. I can’t imagine going beyond my base level of knowledge with vim.

Real programmers use cat.

Realer programmers know about tac.

*Legion* wrote:

Neovim makes an important change to the Vim concept, Vim comes in behind them with a version that's different for the sake of being different (severe NIH syndrome) and minimal acknowledgement that Neovim's the one who broke the ground.

That's a take. Having run an Open Source project where feature requests were at times baldly "make this feature so I don't have to pay for this other product", I usually only implemented such a feature when I had something new to add to it. Copying someone else's features if boring.

Kurrelgyre wrote:

Realer programmers know about tac.

IMAGE(https://c.tenor.com/m_p8mFqA2FQAAAAC/i-am-not-worthy-not-worthy.gif)

Kurrelgyre wrote:

I usually only implemented such a feature when I had something new to add to it. Copying someone else's features if boring.

OK, but Neovim isn't really a "someone else" from Vim, it's a fork. Lots of open source projects cherry pick changes and/or accept patches from the forks that split off of them.

The part I left out is: these features Neovim implemented? They're things Vim users wanted for years. Vim's developers (or, more accurately, Bram) didn't want to implement those things. OK, fine, that's his prerogative. So people finally get fed up, fork the project into Neovim, then add those features.

Then, with people bailing on Vim and switching to Neovim, suddenly Bram does want these things in Vim, but it can't be Neovim's implementation, it can't be a compatible implementation to ensure automatic compatibility with plugins that utilize Neovim's implementation either. No, it has to be Bram's blessed implementation, different but not meaningfully better (or worse).

Which, sure, again, that's his prerogative. And it's everyone else's prerogative to say that Neovim is the real Vim now, and "old" Vim is just Bram's vanity legacy project.

When I say "Vim" these days, I 1000% mean Neovim.

Just writing shell functions boss, being very productive today...

cd () { if [ $# -eq 0 ] then echo "cdeez nuts" builtin cd ~ else builtin cd "[email protected]" fi }
*Legion* wrote:

Just writing shell functions boss, being very productive today...

cd () { if [ $# -eq 0 ] then echo "cdeez nuts" builtin cd ~ else builtin cd "[email protected]" fi }

I’ve never known to use builtin.

Most, if not all, of Pragmatic Programmers books on Elixir are available as a Humble Bundle:

https://www.humblebundle.com/books/e...

At the time of this post, just under four days left for the offer.

Over the past few years, I've paid ~retail price to read most of the books on offer and, while I don't use Elixir for my day job, being exposed to these ideas has fundamentally changed my approach to programming for the better.

$18 for 19 books is an absolute steal and I suggest taking a look if you're even remotely interested.