Skip to content

Commit 959d458

Browse files
Merge pull request rails#48551 from abaldwin88/document_dev_container_cli
Document Dev Container CLI setup in guides
2 parents 860967d + e4002fc commit 959d458

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

guides/source/contributing_to_ruby_on_rails.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,17 @@ If you're a member of an organization that has codespaces enabled, you can fork
196196

197197
If you have [Visual Studio Code](https://code.visualstudio.com) and [Docker](https://www.docker.com) installed, you can use the [VS Code remote containers plugin](https://code.visualstudio.com/docs/remote/containers-tutorial). The plugin will read the [`.devcontainer`](https://github.com/rails/rails/tree/main/.devcontainer) configuration in the repository and build the Docker container locally.
198198

199+
#### Using Dev Container CLI
200+
201+
Alternatively, with [Docker](https://www.docker.com) and [npm](https://github.com/npm/cli) installed, you can run [Dev Container CLI](https://github.com/devcontainers/cli) to utilize the [`.devcontainer`](https://github.com/rails/rails/tree/main/.devcontainer) configuration from the command line.
202+
203+
```bash
204+
$ npm install -g @devcontainers/cli
205+
$ cd rails
206+
$ devcontainer up --workspace-folder .
207+
$ devcontainer exec --workspace-folder . bash
208+
```
209+
199210
#### Using rails-dev-box
200211

201212
It's also possible to use the [rails-dev-box](https://github.com/rails/rails-dev-box) to get a development environment ready. However, the rails-dev-box uses Vagrant and Virtual Box which will not work on Macs with Apple silicon.

0 commit comments

Comments
 (0)