Use Any Host with Spin
Spin is designed to work self-hosting first, which makes it compatible with almost any host. This includes running servers on a major cloud provider down to an old computer running in your grandmother's basement 🤠. Check our server requirements for more details.
Server Requirements
Make sure your server and host meet the minimum server requirements.
View the Spin Server Requirements →
Ensure you're able to connect to your server via SSH
Since you'll have to take care of the set up manually, ensure you can connect to your server via SSH.
Confirm SSH access
# Replace 1.2.3.4 with your server's IP address
ssh root@1.2.3.4
Configure users
Make sure you configure your system users in your .spin.yml
file.
Example users configuration in .spin.yml
##############################################################
# 👇 Users - You must set at least one user
##############################################################
users:
- username: alice
name: Alice Smith
groups: ['sudo']
authorized_keys:
- public_key: "ssh-ed25519 AAAAC3NzaC1lmyfakeublickeyMVIzwQXBzxxD9b8Erd1FKVvu alice"
You can remove "providers" and "hardware_profiles" if you want
By default, the .spin.yml
file includes some defaults for providers and hardware profiles. You can remove these if you want to use your own.
❌ You can remove these lines if you want
# ##############################################################
# # 👇 Providers - You must set at least one provider
# ##############################################################
# providers:
# - name: digitalocean
# api_token: Set token here OR delete this line and set environment variable DO_API_TOKEN
# - name: hetzner
# api_token: Set token here OR delete this line and set environment variable HCLOUD_TOKEN
# - name: vultr
# api_token: Set token here OR delete this line and set environment variable VULTR_API_KEY
# ##############################################################
# # 🤖 Hardware Profiles
# ##############################################################
# hardware_profiles:
# # Hetzner
# - name: hetzner_2c_2gb_ubuntu2404
# provider: hetzner
# profile_config:
# location: ash
# server_type: cpx11
# image: ubuntu-24.04
# backups: true
# # Vultr
# - name: vultr_1c_1gb_ubuntu2404
# provider: vultr
# profile_config:
# region: ord
# plan: vc2-1c-1gb
# os: "Ubuntu 24.04 LTS x64"
# backups: true
# # DigitalOcean
# - name: digitalocean_1c_1gb_ubuntu2404
# provider: digitalocean
# profile_config:
# region: nyc3
# size: s-1vcpu-1gb
# image: ubuntu-24-04-x64
# backups: true
Set your server address under "servers"
If you use our native providers with Spin, it will automatically create and populate the address
property for you. Since in this case we're providing our own server, we'll need to set the address
property for the server in the .spin.yml
file.
.spin.yml
##############################################################
# 👇 Servers - You must set at least one server
##############################################################
servers:
- server_name: my-awesome-server
environment: production
address: 1.2.3.4 # 👈 Be sure to set this to your server's IP address or DNS hostname
# hardware_profile: hetzner_2c_2gb_ubuntu2404 (❌ You can comment or delete this line out)
You can use the IP address or hostname of your server. Feel free to remove the hardware_profile
property if you do not plan to use any providers.
Provision your server
Once you have everything ready, you can provision your server(s) with the following command:
Provision your server(s)
spin provision -u root
⚠️ Most cloud providers (DigitalOcean, Vultr, Hetzner) use root
as the default user. If your server uses a different sudo user, replace root
with that username.
To learn more about this process, see the guide below:
Learn more about "spin provision" →
Troubleshooting SSH Connection
If you encounter connection issues, verify your SSH access first:
Verify SSH access
ssh root@1.2.3.4 # Replace with your username and server IP
You should be able to connect using SSH key authentication without being prompted for a password.
Getting ready for deployment
Now that you have a server ready, you'll want to learn how to get ready for deployment. Next steps are to choose a deployment strategy.