Multiple Accounts and Git

If you have multiple accounts to use with Git — such as a personal and a work account — you can have your Git Config (typically ~/.gitconfig) conditionally include other configs depending on the folder you’re working in. In those extra configs you then can override some settings. Here’s an example ~/.gitconfig that has two …

SSH: Skip Private Keys loaded into ssh-agent

Note to self: to SSH into a server with a username + password combination only — e.g. skipping any Private Key loaded into ssh-agent — use this command: ssh -o PreferredAuthentications=password user@server The connection will now ask for the user’s password, instead of trying to use public key authentication.

A visual guide to SSH tunnels

Great work by Linmiao Xu: SSH tunnels are encrypted TCP connections between SSH clients and servers that allows traffic entering one side of the tunnel to transparently exit through the other. This page explains use cases and examples of SSH tunnels while visually presenting the traffic flows. Also comes with the commands … handy! A …

Using the Numpad in vi over SSH

One of the things that kept on bothering me when SSH’ing is that the keys of the numpad would not work in vi: when pressing any key on the numpad, another key would be sent somehow. Should’ve Google’d this a lot earlier because the fix is very simple: in the preferences of Terminal, go to …

Execute commands over SSH from PHP with spatie/ssh

A new PHP package released by the fine folks at Spatie is spatie/ssh. Leveraging Symfony\Component\Process\Process it allows you to execute commands over SSH from within your PHP code. spatie/ssh is probably the easiest way to perform a quick SSH command. It doesn’t have a lot of features, but that’s ok. It’s intended as something very …

Why aren’t we using SSH for everything?

ssh http://t.co/E7Ilc0B0BC pic.twitter.com/CqYBR1WYO4 — Andrey Petrov (@shazow) December 13, 2014 If we can write a chatroom on top of SSH, why don’t we use it for more things? Interesting read packed with dozens of facts about the SSH protocol and why we should use it for more things. Why aren’t we using SSH for everything? …

Commando.io – Manage servers easily online

Never type the same commands into multiple terminal windows again! From a technological point of view I’m impressed by this I must say! Not sure if I’d use it though (the shell works fine for me). Could be handy if you want to give some people limited (or monitored) shell access to a certain server. …