Member-only story
Rails 7.1 Beta Eases Docker Releases And Boosts Javascript With Bun
Rails 7.1 Beta closes over 30 000 tickets and makes releasing Rails apps with Docker so easy. Bun powered Javascript and Typescript is a great early adoption.
I got a little bit nostalgic after recognizing that last time I wrote about Rails in November last year.
It was one of my first articles after years when I was unable to write. Now after a year writing everyday an article about interesting things happening in software engineering, I’m coming back with some interesting news about Rails.
Back in 2022 I had like 100 followers, now I have 6600, with 2000 expected to join this month
Rails 7.1 beta was just released.
Production Docker Files Are Now Generated
Now when running rails new, Rails will set up optimised Docker files, so you can start a production ready app right away.
If you don’t need these files you can append --skip-docker parameter.
What’s important to notice, it adds production Docker files. If you want to develop Rails app that’s inside a Docker, you should still use Docked Rails CLI.
If you’re interested how the generated Dockerfile looks as for now, check this file.
What’s important, the Dockerfile references the slim version of Ruby Docker image. This is an example of the size of Ruby 3.2.2 image in the standard version:
And that’s the slim version:
It’s five times smaller. Other interesting thing to notice is that Node.js will be installed only when you use it saving again hundreds of MiB.
If you’ll use it, yarn package manager will be available out of the box.