31. 問題 例外を吐くと .... This is the Postfix program at host snares.example.com. : The Postfix program >test@example.com< : Command died with status 1: "/var/MailApp/mailserver/test.rb". Command output: /usr/lib/ruby/1.8/logger.rb:518:in `initialize': Permission denied - /var/MailApp/mailserver/../log/MailServer.log (Errno::EACCES) from /usr/lib/ruby/1.8/logger.rb:518:in `open' from /usr/lib/ruby/1.8/logger.rb:518:in `open_logfile' from ユーザー宛にエラーメール
36. require 'net/pop' task :mail_fetcher => [:environment] do @config = YAML.load(IO.read("#{RAILS_ROOT}/config/mail_fetcher.yml")) daemonize() loop do pop = Net::POP3.new(@config[RAILS_ENV]['server']) pop.start(@config[RAILS_ENV]['username'], @config[RAILS_ENV]['password']) unless pop.mails.empty? pop.each_mail do |m| IncomingMailHandler.receive(m.pop) m.delete end end pop.finish sleep(SLEEP_TIME) end end