How to use a Rails environment variable in Capistrano deploy script?
capistrano, ruby-on-rails
Solution
This ended up working:
created a file `config/initializers/my_constant.rb`
put my constant in there (rails automatically loads files there so I can use the constant in my app)
then in deploy.rb added `load 'config/initializers/my_constant'` so it could be used there as well.
Problem
If I have a constant in my Rails environment.rb, for example... ``` SOME_CONSTANT = 3 ``` Is it possible to access this in my capistrano deploy.rb somehow? It seems simple but I can't figure out how.