Skip to content

Commit 6062444

Browse files
Fixed small nits after the review
1 parent c7fdf94 commit 6062444

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

content/guides/ruby/containerize.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,15 @@ This section walks you through containerizing and running a [Ruby on Rails](http
2222

2323
Starting from Rails 7.1 [Docker is supported out of the box](https://guides.rubyonrails.org/7_1_release_notes.html#generate-dockerfiles-for-new-rails-applications). This means that you will get a `Dockerfile`, `.dockerignore` and `bin/docker-entrypoint` files generated for you when you create a new Rails application.
2424

25-
If you have an existing Rails application, you will need to create the Docker assets manually. Unfortunately `docker init` command does not yet support Rails. This means that if you are working with Rails, you'll need to copy Dockerfile and other related configurations manually from the examples below.
25+
If you have an existing Rails application, you will need to create the Docker assets manually. Unfortunately `docker init` command does not yet support Rails. This means that if you are working with Rails, you'll need to copy Dockerfile and other related configurations manually from the examples below.
2626

2727
## Initialize Docker assets
2828

2929
Rails 7.1 generates multistage Dockerfile out of the box, below is an example of such file generated from a Rails template.
3030

31-
> Multistage Dockerfiles help create smaller, more efficient images by separating build and runtime dependencies, ensuring only necessary components are included in the final image. Read more about multi-stage builds [in a dedicated article](/get-started/docker-concepts/building-images/multi-stage-builds/)
31+
> Multistage Dockerfiles help create smaller, more efficient images by separating build and runtime dependencies, ensuring only necessary components are included in the final image. Read more in the [Multi-stage builds guide](/get-started/docker-concepts/building-images/multi-stage-builds/).
3232
33-
Even though the Dockerfile is generated for you, it's a good idea to understand what it does and how it works, so we recommend reading the following example.
33+
Although the Dockerfile is generated automatically, understanding its purpose and functionality is important. Reviewing the following example is highly recommended.
3434

3535

3636
```dockerfile {title=Dockerfile}
@@ -135,7 +135,7 @@ EXPOSE 3000
135135
CMD ["./bin/rails", "server"]
136136
```
137137

138-
We specified the Docker entrypoint as `./bin/docker-entrypoint` which is a script that prepares the database and runs the application server. Below is an example of such a script.
138+
This Dockerfile uses a script at `./bin/docker-entrypoint` as the container's entrypiont. This script prepares the database and runs the application server. Below is an example of such a script.
139139

140140
```bash {title=docker-entrypoint}
141141
#!/bin/bash -e
@@ -206,7 +206,7 @@ Besides the two files above you will also need a `.dockerignore` file. This file
206206
/Dockerfile*
207207
```
208208

209-
The last thing that may be necessary, but not always required is `compose.yml` file, used by Docker Compose to define the services that make up your application. Since we are using SQLite as the database, we don't need to define a separate service for the database, and the only service we need is the Rails application itself.
209+
The last optional file that you may want is the `compose.yaml` file, which is used by Docker Compose to define the services that make up the application. Since SQLite is being used as the database, there is no need to define a separate service for the database. The only service required is the Rails application itself.
210210

211211
```yaml {title=compose.yaml}
212212
services:

0 commit comments

Comments
 (0)