# Rails getting started with dev containers should not be dependent on require rails-new or vscode

**URL:** <https://discuss.rubyonrails.org/t/rails-getting-started-with-dev-containers-should-not-be-dependent-on-require-rails-new-or-vscode/88946>\
**Category:** rubyonrails-docs\
**Created:** [March 26, 2025, 1:29pm UTC](https://discuss.rubyonrails.org/t/rails-getting-started-with-dev-containers-should-not-be-dependent-on-require-rails-new-or-vscode/88946 "2025-03-26T13:29:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![SamuelFrost](https://sea2.discourse-cdn.com/rubyonrails/user_avatar/discuss.rubyonrails.org/samuelfrost/32/13268_2.png) [@SamuelFrost](https://discuss.rubyonrails.org/u/SamuelFrost)\
**Post date:** [March 26, 2025, 1:29pm UTC](https://discuss.rubyonrails.org/t/rails-getting-started-with-dev-containers-should-not-be-dependent-on-require-rails-new-or-vscode/88946/1 "2025-03-26T13:29:33Z")

</div>

I’ve been working out what my ideal development environment set up process is, and since I love docker, I like to have everything for the development environment work with a simple ‘docker compose up’, maybe with a --build option thrown on there.

I had hopes when I saw the getting\_started\_with\_devcontainer guide, but ultimately it disappoints me that I still have to download and manage an executable service on my device with rails-new.

> **[Getting Started with Dev Containers — Ruby on Rails Guides](https://guides.rubyonrails.org/getting_started_with_devcontainer.html)**
>
> Getting Started with Dev ContainersAfter reading this guide, you will know: How to create a new Rails application with the rails-new tool. How to begin working with your application in a development container.

Futhermore, I like the idea of having an option to initialize a development environment dockerfile designed to be agnostic development environment, as opposed to the whole devcontainer.json stuff. It should generate a development dockerfile (in addition to the production ready one) with a sensible minimalistic default setup with some comments for common development niceties.

I apologize if I seem to be missing the point of the guide/dockerization goals going on for rails; I don’t mean to criticize the devcontainer way, I just want a no dependency way as well.

As for my thoughts on resolving the initialization aspect of the matter, I’ve decided to use this to initialize rails apps myself. Only requiring docker (and a linux kernel for it to run on).

```bash
docker run --rm --volume ${PWD}:/app --workdir /app --user $(id -u):$(id -g) ruby:latest bash -c "gem install rails && rails new myapp --database=postgresql"

```

It might need to be refined a bit, but I think we should probably make a no setup way to quickly get a rails project running without having to configure our local machine.

---

<div class="post-metadata">

**Author:** ![DanielLenz](https://avatars.discourse-cdn.com/v4/letter/d/65b543/32.png) [@DanielLenz](https://discuss.rubyonrails.org/u/DanielLenz)\
**Post date:** [August 18, 2026, 6:21pm UTC](https://discuss.rubyonrails.org/t/rails-getting-started-with-dev-containers-should-not-be-dependent-on-require-rails-new-or-vscode/88946/2 "2026-08-18T18:21:07Z")

</div>

Hey,

I like your approach. Devcontainer with non-root docker are very complicated I think.

The default created with rails-new --devcontainer will not work with rootless docker.

Best regards,

Daniel
