Create a Hetzner backend
Create Hetzner “Project” and “Add Server”.
- Add ssh key.
- No volumes or any of the rest.
Set server name to myapp.
Copy ip address and add new dns record in Cloudflare:
A edge x.x.x.x Proxied.
Add host to ssh config.
Ssh into root@myapp,
Install tools:
apt update
apt install -y docker.io docker-cli docker-compose-v2 make tmux
Create app user (use openssl rand -hex 16 to generate a password):
adduser --gecos "" --home /home/app --shell /bin/bash app
usermod -aG docker app
Copy public key to Hetzner app user:
ssh-copy-id -i ~/.ssh/mykey.pub app@myapp
Copy tmux.conf from another server to myapp:
scp anotherapp:.tmux.conf myapp:
Login as app:
ssh myapp
git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
In tmux, press <mod>+I to install it.