Re: Mephisto and read only file system
Thanks for the reply Morten, I dont know if I've got the time to get too sidetracked. I just wanted a simple cms that was pretty "plug and play" for a small club site.. Radiant put me off with its non standard application structure so I thought I'd give Mephisto a shot. I'm not really even sure its the solution I want but surprisingly there dont seem to be many cms apps in Rails... Cheers George On May 12, 8:40 am, Morten Bagai wrote: > Hey, > > I was actually just playing with this yesterday. I was able to get it > to work, by patching lib/mephisto/theme_root so that it puts themes > in /tmp like this: > > THEME_ROOT = Pathname.new(RAILS_ROOT) + "tmp/" + > (Rails.env.production? ? "themes" : "themes/#{Rails.env}") > > It worked, but it's clearly not a sustainable solution since themes > shouldn't really go in /tmp. How to do it right seems like a slightly > tricky question to me, actually, since you both have themes that are > copied and runtime-generated. > > If you're interested in fooling around with it, I'd be happy to share > my tweaked version with you. It also includes the right .gems file to > get mephisto's (many) dependencies installed on Heroku. > > Best, > > Morten > > On May 10, 2009, at 3:41 AM, giorgio wrote: > > > > > Hi, > > > I read Adam's entry that he had got Mephisto running on heroku... > > > However I get read only file system errors. > > > Is there any work around? > > > Here's the stack trace: > > > Processing MephistoController#dispatch (for 203.97.nnn.nnn at > > 2009-05-10 03:35:29) [GET] > > Parameters: {"action"=>"dispatch", "controller"=>"mephisto", "path"=> > > []} > > > Errno::EROFS (Read-only file system - /disk1/home/slugs/ > > 14579_c8bad6a_f265/mnt/themes/site-1 - Heroku has a read-only > > filesystem. Seehttp://heroku.com/docs#toc59): > >/usr/local/lib/ruby/1.8/fileutils.rb:243:in `mkdir' > >/usr/local/lib/ruby/1.8/fileutils.rb:243:in `fu_mkdir' > >/usr/local/lib/ruby/1.8/fileutils.rb:217:in `mkdir_p' > >/usr/local/lib/ruby/1.8/fileutils.rb:215:in `reverse_each' > >/usr/local/lib/ruby/1.8/fileutils.rb:215:in `mkdir_p' > >/usr/local/lib/ruby/1.8/fileutils.rb:201:in `each' > >/usr/local/lib/ruby/1.8/fileutils.rb:201:in `mkdir_p' > >/app/models/site.rb:147:in `themes' > >/app/models/site.rb:159:in `theme' > >(__DELEGATION__):2:in `templates' > >/app/models/site.rb:244:in `find_preferred_template' > >/app/models/site.rb:304:in `set_content_template' > >/app/models/site.rb:201:in `call_render' > >/app/controllers/application.rb:87:in `render_liquid_template_for' > >/app/controllers/mephisto_controller.rb:29:in `dispatch_list' > >/app/controllers/mephisto_controller.rb:11:in `send' > >/app/controllers/mephisto_controller.rb:11:in `dispatch' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/base.rb:1253:in `send' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/base.rb:1253:in `perform_action_without_filters' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:617:in `call_filters' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:638:in `run_before_filters' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:206:in `call' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:206:in `around_proc' > >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > > active_support/callbacks.rb:182:in `call' > >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > > active_support/callbacks.rb:182:in `evaluate_method' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:184:in `call' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:635:in `run_before_filters' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:615:in `call_filters' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:638:in `run_before_filters' > >/app/controllers/application.rb:108:in `get_requests_are_readonly' > >/config/initializers/readonly_records.rb:18:in > > `with_readonly_records' > >/app/controllers/application.rb:107:in `get_requests_are_readonly' > >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > > active_support/callbacks.rb:178:in `send' > >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > > active_support/callbacks.rb:178:in `evaluate_method' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:186:in `call' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_controller/filters.rb:635:in `run_before_filters' > >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > > action_co
Re: Mephisto and read only file system
Hey, I was actually just playing with this yesterday. I was able to get it to work, by patching lib/mephisto/theme_root so that it puts themes in /tmp like this: THEME_ROOT = Pathname.new(RAILS_ROOT) + "tmp/" + (Rails.env.production? ? "themes" : "themes/#{Rails.env}") It worked, but it's clearly not a sustainable solution since themes shouldn't really go in /tmp. How to do it right seems like a slightly tricky question to me, actually, since you both have themes that are copied and runtime-generated. If you're interested in fooling around with it, I'd be happy to share my tweaked version with you. It also includes the right .gems file to get mephisto's (many) dependencies installed on Heroku. Best, Morten On May 10, 2009, at 3:41 AM, giorgio wrote: > > Hi, > > I read Adam's entry that he had got Mephisto running on heroku... > > However I get read only file system errors. > > Is there any work around? > > Here's the stack trace: > > Processing MephistoController#dispatch (for 203.97.nnn.nnn at > 2009-05-10 03:35:29) [GET] > Parameters: {"action"=>"dispatch", "controller"=>"mephisto", "path"=> > []} > > > Errno::EROFS (Read-only file system - /disk1/home/slugs/ > 14579_c8bad6a_f265/mnt/themes/site-1 - Heroku has a read-only > filesystem. See http://heroku.com/docs#toc59): >/usr/local/lib/ruby/1.8/fileutils.rb:243:in `mkdir' >/usr/local/lib/ruby/1.8/fileutils.rb:243:in `fu_mkdir' >/usr/local/lib/ruby/1.8/fileutils.rb:217:in `mkdir_p' >/usr/local/lib/ruby/1.8/fileutils.rb:215:in `reverse_each' >/usr/local/lib/ruby/1.8/fileutils.rb:215:in `mkdir_p' >/usr/local/lib/ruby/1.8/fileutils.rb:201:in `each' >/usr/local/lib/ruby/1.8/fileutils.rb:201:in `mkdir_p' >/app/models/site.rb:147:in `themes' >/app/models/site.rb:159:in `theme' >(__DELEGATION__):2:in `templates' >/app/models/site.rb:244:in `find_preferred_template' >/app/models/site.rb:304:in `set_content_template' >/app/models/site.rb:201:in `call_render' >/app/controllers/application.rb:87:in `render_liquid_template_for' >/app/controllers/mephisto_controller.rb:29:in `dispatch_list' >/app/controllers/mephisto_controller.rb:11:in `send' >/app/controllers/mephisto_controller.rb:11:in `dispatch' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/base.rb:1253:in `send' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/base.rb:1253:in `perform_action_without_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:617:in `call_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:638:in `run_before_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:206:in `call' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:206:in `around_proc' >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > active_support/callbacks.rb:182:in `call' >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > active_support/callbacks.rb:182:in `evaluate_method' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:184:in `call' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:635:in `run_before_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:615:in `call_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:638:in `run_before_filters' >/app/controllers/application.rb:108:in `get_requests_are_readonly' >/config/initializers/readonly_records.rb:18:in > `with_readonly_records' >/app/controllers/application.rb:107:in `get_requests_are_readonly' >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > active_support/callbacks.rb:178:in `send' >/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ > active_support/callbacks.rb:178:in `evaluate_method' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:186:in `call' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:635:in `run_before_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:615:in `call_filters' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/filters.rb:610:in `perform_action_without_benchmark' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/benchmarking.rb:68:in > `perform_action_without_rescue' >/usr/local/lib/ruby/1.8/benchmark.rb:293:in `measure' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/benchmarking.rb:68:in > `perform_action_without_rescue' >/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ > action_controller/rescue.rb:13
Mephisto and read only file system
Hi, I read Adam's entry that he had got Mephisto running on heroku... However I get read only file system errors. Is there any work around? Here's the stack trace: Processing MephistoController#dispatch (for 203.97.nnn.nnn at 2009-05-10 03:35:29) [GET] Parameters: {"action"=>"dispatch", "controller"=>"mephisto", "path"=> []} Errno::EROFS (Read-only file system - /disk1/home/slugs/ 14579_c8bad6a_f265/mnt/themes/site-1 - Heroku has a read-only filesystem. See http://heroku.com/docs#toc59): /usr/local/lib/ruby/1.8/fileutils.rb:243:in `mkdir' /usr/local/lib/ruby/1.8/fileutils.rb:243:in `fu_mkdir' /usr/local/lib/ruby/1.8/fileutils.rb:217:in `mkdir_p' /usr/local/lib/ruby/1.8/fileutils.rb:215:in `reverse_each' /usr/local/lib/ruby/1.8/fileutils.rb:215:in `mkdir_p' /usr/local/lib/ruby/1.8/fileutils.rb:201:in `each' /usr/local/lib/ruby/1.8/fileutils.rb:201:in `mkdir_p' /app/models/site.rb:147:in `themes' /app/models/site.rb:159:in `theme' (__DELEGATION__):2:in `templates' /app/models/site.rb:244:in `find_preferred_template' /app/models/site.rb:304:in `set_content_template' /app/models/site.rb:201:in `call_render' /app/controllers/application.rb:87:in `render_liquid_template_for' /app/controllers/mephisto_controller.rb:29:in `dispatch_list' /app/controllers/mephisto_controller.rb:11:in `send' /app/controllers/mephisto_controller.rb:11:in `dispatch' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/base.rb:1253:in `send' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/base.rb:1253:in `perform_action_without_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:617:in `call_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:638:in `run_before_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:206:in `call' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:206:in `around_proc' /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ active_support/callbacks.rb:182:in `call' /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ active_support/callbacks.rb:182:in `evaluate_method' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:184:in `call' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:635:in `run_before_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:615:in `call_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:638:in `run_before_filters' /app/controllers/application.rb:108:in `get_requests_are_readonly' /config/initializers/readonly_records.rb:18:in `with_readonly_records' /app/controllers/application.rb:107:in `get_requests_are_readonly' /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ active_support/callbacks.rb:178:in `send' /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/ active_support/callbacks.rb:178:in `evaluate_method' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:186:in `call' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:635:in `run_before_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:615:in `call_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:610:in `perform_action_without_benchmark' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/benchmarking.rb:68:in `perform_action_without_rescue' /usr/local/lib/ruby/1.8/benchmark.rb:293:in `measure' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/benchmarking.rb:68:in `perform_action_without_rescue' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/rescue.rb:136:in `perform_action_without_caching' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/caching/sql_cache.rb:13:in `perform_action' /usr/local/lib/ruby/gems/1.8/gems/activerecord-2.2.2/lib/ active_record/connection_adapters/abstract/query_cache.rb:34:in `cache' /usr/local/lib/ruby/gems/1.8/gems/activerecord-2.2.2/lib/ active_record/query_cache.rb:8:in `cache' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/caching/sql_cache.rb:12:in `perform_action' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/base.rb:524:in `send' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/base.rb:524:in `process_without_filters' /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/ action_controller/filters.rb:606:in `process_without_session_management_support' /usr/local/lib/ruby/gems/1