Your server
andamio serverYou can run it as many times as you want: it resumes where it stopped, and it’s also how you re-apply everything after a change.
Only lock down the VPS: andamio security
Section titled “Only lock down the VPS: andamio security”If for now you only want the VPS safe (or you’ll set up the platform later):
andamio securityIf you come from andamio setup choosing “only lock down my VPS”, it starts by itself. It asks:
- the VPS’s IP;
- where it is (Azure, AWS, Hetzner…) and the user your provider gave you (the one that
already exists:
azureuser,ubuntu,rootor the one you picked when creating it); - your new user, different from the provider’s (if you type the same, it’s refused right away). The provider’s keeps existing and works on its web console, but can no longer log in over SSH;
- the new SSH port: Enter takes a random one. If your provider has a firewall, that’s where you open this same number (andamio tells you if you forget);
- the name to log in with (
ssh <name>): it suggests one that says which server it is.
And it does the same as andamio server’s lockdown, without installing anything else:
- Creates your SSH key if you don’t have one, and warns you it’ll be your only way in (keep it).
- Checks the server’s fingerprint and installs your key with the password or
.pemyour provider gave you (once). - Before moving SSH, it tests that the new port reaches the server. If your provider’s firewall blocks it, it stops and tells you where to open it: you don’t get locked out. Open it and run the command again: it resumes where it stopped.
- Creates your user and, in the same step, turns off passwords and root and turns on the firewall.
- Checks it from outside: root and the other users get refused with a password, and
22no longer answers. - Automatic patches, strict sshd and fail2ban.
- Applies the pending patches your provider’s image ships with right away and, if they need a reboot (the kernel), offers to do it now: nothing runs on the server yet.
- The server’s security check, all in view.
Safe to repeat: what’s done is skipped.
When you want the platform: if your copy is local only (setup made it when you chose “only
lock down”), andamio setup inside it connects it to GitHub. Then andamio init fills in
what’s missing (domain, repo, HTTPS) without asking the above again, and andamio server.
Before: two checks at your provider
Section titled “Before: two checks at your provider”-
Its firewall. Azure, AWS, Oracle and Google Cloud (and some Hetzner or DigitalOcean setups) filter traffic before it reaches your VPS. Open inbound TCP for your SSH port,
80and443, and UDP51820. Keep22open untilandamio serverfinishes: otherwise you’re locked out when SSH moves to your port. -
The server’s fingerprint.
andamio servershows it before the first connection. Check it from inside the server through a path that isn’t the network: your VPS’s web console, Run command on Azure or Session Manager on AWS:Ventana de terminal ssh-keygen -lf /etc/ssh/ssh_host_ed25519_key.pubIt has to match. If it doesn’t, stop: someone may be in the middle.
What it does, step by step
Section titled “What it does, step by step”- Gets into the server with what your provider gave you: a root password or the
.pemkey. It asks which provider you use, to know its initial user. - Installs your SSH key and verifies the fingerprint.
- Creates your user for operations and asks for a new sudo password (twice).
- Hardens it: key-only SSH on your port, no root login and its password locked, UFW firewall (all three as soon as your user exists, before going on), fail2ban, automatic security patches and unused services removed.
- Installs Docker (rotated logs; the socket only through a read-only proxy).
- Sets up the WireGuard VPN and generates your first device’s configuration.
- Prepares the key the server uses to pull your copy of andamio (read-only, that repo only).
- Starts the platform: Traefik with HTTPS, PostgreSQL, Redis and monitoring.
When it’s done, close 22 in your provider’s firewall.
The VPN
Section titled “The VPN”Your first device is in ~/andamio-vpn/mi-pc.conf. Import it in the WireGuard app; for your
phone, show it as a QR code:
qrencode -t ansiutf8 < ~/andamio-vpn/mi-pc.confPrivate apps (the ones you create without --public) and the admin tools answer only
with the VPN connected.
Check that it’s right
Section titled “Check that it’s right”andamio statusChecks the server’s security and health from inside and from the internet, and tells you how to fix each problem. See Security.
Your sudo password
Section titled “Your sudo password”Commands that change the server ask for it once and remember it for 15 idle minutes, in
memory only (never on disk). In the panel, Settings → Sudo password picks how long: 15 min,
1 h, 4 h or 8 h (a preference of your machine, in ~/.config/andamio), and Forget now wipes
it. In the terminal, andamio forget does the same; ANDAMIO_SUDO_MINUTES overrides the setting
(0 turns remembering off).