Skip to content

Conversation

orbanbotond
Copy link

@orbanbotond orbanbotond commented Sep 9, 2025

Fix #278

The problem:
When we run the bundle exec rails solid_cache:install, it generated a cache.yml file which contains the reference to the cache database only for production mode.
(Personal Note: As I was testing the cache in development, I was expecting that the generated file would be perfect for all environments. Then I would turn on the caching for the development environment in the development.rb by config.cache_store = :solid_cache_store if I wanted to. But I was surprised. My eyes just jumped over the missing database:... part in the cache.yml file, so I spent about 20 minutes figuring out what was wrong. If we multiply that 20 minutes by 10000 devs who are struggling, then that is a lot of lost hours ~3300)

The solution:
Generate a ready-to-use cache file.

This decision is up to you (37signal) guys :) I just want to be helpful.

Some other guys were also struggling with this issue:
https://www.reddit.com/r/rails/comments/1gws1fp/help_needed_with_solid_cache/

@AliSepehri
Copy link

I agree, not having solid_cache setup for development is confusing. But this PR changes requires also a change in Rails repo to consider cache in database.yml file otherwise it will fail by default.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

As I run bin/rails solid_cache:install it generates a cache.yml which doesn't contain a reference to a database for the dev mode.

2 participants