Your First Instance
A complete walkthrough from a fresh install to a running EC2 instance and back. Allow 15–20 minutes.
What you'll accomplish
- spawn and truffle installed and working
- AWS credentials verified
- An EC2 instance running in AWS
- An active SSH connection to that instance
- The instance terminated when you're done
Prerequisites
- An AWS account (free tier works fine)
- macOS, Linux, or Windows with WSL2
- Basic comfort with the command line
1. Install
brew install spore-host/tap/truffle
brew install spore-host/tap/spawnVerify:
truffle --version
spawn --versionIf you're not on macOS or need a different install method, see the Installation guide.
2. Check your AWS credentials
aws sts get-caller-identityExpected output:
{
"UserId": "AIDAIOSFODNN7EXAMPLE",
"Account": "123456789012",
"Arn": "arn:aws:iam::123456789012:user/yourname"
}If this fails, run aws configure and enter your Access Key ID, Secret Access Key, and preferred region. spore.host uses the same credentials as the AWS CLI — nothing extra to configure.
3. Find a cheap instance
Before launching, see what's available and what it costs:
truffle find "t3 medium" --region us-east-1You'll see a table with vCPUs, memory, and on-demand price. For this walkthrough we'll use a t3.micro — free tier eligible.
4. Launch
spawn launch \
--name my-first-instance \
--instance-type t3.micro \
--ttl 1hAfter about 60–90 seconds:
✓ Instance i-0a1b2c3d4e5f running
✓ my-first-instance.abc123.spore.host
✓ SSH: ssh ec2-user@54.123.45.67
✓ Auto-terminates in 1hspawn automatically found the latest Amazon Linux 2023 AMI, created an SSH key, configured networking, and installed spored on the instance.
5. Connect
spawn connect my-first-instanceThis prints the SSH command. Or connect directly:
ssh ec2-user@54.123.45.67TIP
If you get "Connection refused", the instance is still booting. Wait 30 seconds and try again.
Once connected, confirm spored is running:
sudo systemctl status spored6. Check status from your laptop
In a second terminal:
spawn status my-first-instanceThis shows state, IP, type, uptime, and time remaining before auto-termination.
7. Clean up
When you're done, permanently terminate it (destroys the instance and its EBS volume):
spawn terminate my-first-instance # confirms first; add -y to skipOr spawn stop my-first-instance to keep the EBS volume and resume later — or just leave it, since it auto-terminates after 1 hour (the default idle timeout).
What just happened
spored was installed automatically on the instance. It runs in the background, enforces the TTL, and would detect idle activity if configured. This is the core spore.host contract: every instance knows when to stop.
Next steps
- GPU Training Jobs — launch a GPU instance for a real workload
- Slack Setup — get DM notifications when your instances change state
- spawn launch reference — every flag explained