A minimal Rails 8 starter template with Docker Compose. Get a fully working Rails 8 development environment in seconds. Supports vanilla Rails or MaglevCMS for content management.
git clone https://github.com/mkyed/just-rails-8 my-project
cd my-project
docker compose upOpen http://localhost:3008 - done!
- Zero Configuration - Just
docker compose upand start coding - Ruby 4.0 + Rails 8.1 - Latest stable versions
- Two Flavors:
- Vanilla: Minimal Rails 8 with SQLite
- Maglev CMS: Rails 8 with MaglevCMS 2.1 website builder
- Local Editing - Files mounted as volumes, edit with your favorite IDE
- Persistent Data - Database and gems cached between restarts
docker compose upJR8_FLAVOR=maglev docker compose up./just-rails-8/reset.sh --clean-untrackedJustRails8 is designed as a starting point for new projects:
- Clone or use GitHub's "Use this template" button
- Reset Git history to start fresh:
rm -rf .git git init git add . git commit -m "Initial commit"
- Push to your own repository
.
├── docker-compose.yml # Docker Compose configuration
├── just-rails-8/
│ ├── Dockerfile # Ruby 4.0 image with Rails 8.1
│ ├── setup.sh # Initializes Rails app on first run
│ └── reset.sh # Cleanup script
└── (Rails app files generated on first run)
| Setting | Default | Description |
|---|---|---|
| Port | 3008 | Host port (maps to container 3000) |
| Database | SQLite | Persistent via Docker volume |
JR8_FLAVOR |
vanilla | Set to maglev for CMS |
# Start app
docker compose up
# Rebuild after Dockerfile changes
docker compose up --build
# Rails console
docker compose exec web rails console
# Run migrations
docker compose exec web rails db:migrate
# Stop containers
docker compose down