{"id":14955433,"url":"https://github.com/ryanwi/rails-on-docker","last_synced_at":"2025-09-30T13:30:48.456Z","repository":{"id":37001767,"uuid":"204349906","full_name":"ryanwi/rails-on-docker","owner":"ryanwi","description":"Working Rails 6.1 demo application with PostgreSQL, Docker, jsbundling-rails (with Webpack), and GitHub Actions","archived":false,"fork":false,"pushed_at":"2024-05-31T15:19:29.000Z","size":2132,"stargazers_count":36,"open_issues_count":11,"forks_count":14,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-14T11:14:12.394Z","etag":null,"topics":["docker","github-actions","rails","rails6","webpacker"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ryanwi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-08-25T21:07:14.000Z","updated_at":"2024-09-09T15:28:49.000Z","dependencies_parsed_at":"2023-02-14T18:15:39.113Z","dependency_job_id":"63ff744b-9fe5-449f-9557-6ba938fa65e9","html_url":"https://github.com/ryanwi/rails-on-docker","commit_stats":{"total_commits":839,"total_committers":5,"mean_commits":167.8,"dds":0.4636471990464839,"last_synced_commit":"52ea6a4a3faee005260bb83a311c7dd642e60909"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanwi%2Frails-on-docker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanwi%2Frails-on-docker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanwi%2Frails-on-docker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ryanwi%2Frails-on-docker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ryanwi","download_url":"https://codeload.github.com/ryanwi/rails-on-docker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":234737844,"owners_count":18879180,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","github-actions","rails","rails6","webpacker"],"created_at":"2024-09-24T13:11:09.032Z","updated_at":"2025-09-30T13:30:43.135Z","avatar_url":"https://github.com/ryanwi.png","language":"Ruby","readme":"# Rails 6 on Docker demo application\n\n![Ruby](https://github.com/ryanwi/rails-on-docker/workflows/Ruby/badge.svg)\n\nThis app demonstrates Rails 6 with PostgreSQL and Webpack (with jsbundling-rails), all running in Docker.\n\n**NOTE:** [There is also an example Rails 7 application working in Docker without Webpack or node.js](https://github.com/ryanwi/rails7-on-docker)\n\n## Requirements\n\nPlease ensure you are using Docker Compose V2. This project relies on the `docker compose` command, not the previous `docker-compose` standalone program.\n\nhttps://docs.docker.com/compose/#compose-v2-and-the-new-docker-compose-command\n\nCheck your docker compose version with:\n```\n% docker compose version\nDocker Compose version v2.10.2\n```\n\n## Initial setup\n```\ncp .env.example .env\ndocker compose build\ndocker compose run --rm web bin/rails db:setup\n```\n\n## Running the Rails app\n```\ndocker compose up\n```\n\n## Running the Rails console\nWhen the app is already running with `docker-compose` up, attach to the container:\n```\ndocker compose exec web bin/rails c\n```\n\nWhen no container running yet, start up a new one:\n```\ndocker compose run --rm web bin/rails c\n```\n\n## Running tests\n```\ndocker compose run --rm web bundle exec rspec\n```\n\n## Updating gems\n```\ndocker compose run --rm web bundle update\ndocker compose up --build\n```\n\n## Updating Yarn packages\n```\ndocker compose run --rm web yarn upgrade\ndocker compose up --build\n```\n\n## Webpacker retirement\n\nMany Rails 6 apps will be or were created with the Webpacker gem. On January 19, 2022, [Webpacker announed its retirement](https://github.com/rails/webpacker#webpacker-has-been-retired-). As a result, it has been replaced in this repo with jsbundling-rails based on the recommendation in the announcement.\n\n## Credits/References\n\n* https://docs.docker.com/compose/rails/\n* https://rubyinrails.com/2019/03/29/dockerify-rails-6-application-setup/\n* https://pragprog.com/book/ridocker/docker-for-rails-developers\n* https://evilmartians.com/chronicles/ruby-on-whales-docker-for-ruby-rails-development\n* https://medium.com/@cristian_rivera/cache-rails-bundle-w-docker-compose-45512d952c2d\n* https://github.com/rails/jsbundling-rails/blob/main/docs/switch_from_webpacker.md\n* https://dev.to/thomasvanholder/how-to-migrate-from-webpacker-to-jsbundling-rails-esbuild-5f2\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanwi%2Frails-on-docker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fryanwi%2Frails-on-docker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fryanwi%2Frails-on-docker/lists"}