Menu

Deploy Rails 8 with PostgreSQL and migrations that run before traffic
📰

Deploy Rails 8 with PostgreSQL and migrations that run before traffic

DEV Community: rails·Hüseyin Poyraz Küçükarslan·1 day ago
#J83lVcqp
#devtorails#devto#dev#rails#gregale
Long article (1308 words) — no AI summary yet.
Reading 0:00
15s threshold

Originally published on gregale.dev . I build Gregale, so read this as a vendor's page. Competitor details come from each vendor's own docs, linked in the post. This post was written with AI assistance.

A Rails 8 app generated with rails new --database=postgresql deploys on Gregale from its own Dockerfile with a few changes: upload the vendor/ folder, start Puma directly, run db:migrate from a release script that switches to the migration credential, and drop Active Storage so the image fits. Rails used 257 MB of memory in our test, so it needs the Hobby plan's 512 MB; the Free plan's 256 MB is just too small, and Free has no managed PostgreSQL anyway. The working result is public at gregale-dev/rails-postgres .

Generate the app

rails new blog --database=postgresql --skip-solid --skip-kamal

Enter fullscreen mode

Exit fullscreen mode

--skip-solid leaves out Solid Cache, Solid Queue and Solid Cable.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.