Changeset 6095
- Timestamp:
- 01/31/07 02:09:45 (2 years ago)
- Files:
-
- trunk/actionmailer/CHANGELOG (modified) (1 diff)
- trunk/actionmailer/lib/action_mailer/base.rb (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/actionmailer/CHANGELOG
r5505 r6095 1 1 *SVN* 2 3 * Rename server_settings to smtp settings, and add sendmail_settings to allow you to override the arguments to and location of the sendmail executable. [Koz] 2 4 3 5 * Allow mailer actions named send by using __send__ internally. #6467 [iGEL] trunk/actionmailer/lib/action_mailer/base.rb
r5505 r6095 185 185 # Can be set to nil for no logging. Compatible with both Ruby's own Logger and Log4r loggers. 186 186 # 187 # * <tt>s erver_settings</tt> - Allows detailed configuration of the server:187 # * <tt>smtp_settings</tt> - Allows detailed configuration for :smtp delivery method: 188 188 # * <tt>:address</tt> Allows you to use a remote mail server. Just change it from its default "localhost" setting. 189 189 # * <tt>:port</tt> On the off chance that your mail server doesn't run on port 25, you can change it. … … 194 194 # This is a symbol and one of :plain, :login, :cram_md5 195 195 # 196 # * <tt>sendmail_settings</tt> - Allows you to override options for the :sendmail delivery method 197 # * <tt>:location</tt> The location of the sendmail executable, defaults to "/usr/sbin/sendmail" 198 # * <tt>:arguments</tt> The command line arguments 196 199 # * <tt>raise_delivery_errors</tt> - whether or not errors should be raised if the email fails to be delivered. 197 200 # 198 201 # * <tt>delivery_method</tt> - Defines a delivery method. Possible values are :smtp (default), :sendmail, and :test. 199 # Sendmail is assumed to be present at "/usr/sbin/sendmail".200 202 # 201 203 # * <tt>perform_deliveries</tt> - Determines whether deliver_* methods are actually carried out. By default they are, … … 229 231 cattr_accessor :logger 230 232 231 @@s erver_settings = {233 @@smtp_settings = { 232 234 :address => "localhost", 233 235 :port => 25, … … 237 239 :authentication => nil 238 240 } 239 cattr_accessor :server_settings 241 cattr_accessor :smtp_settings 242 243 @@sendmail_settings = { 244 :location => '/usr/sbin/sendmail', 245 :arguments => '-i -t' 246 } 247 cattr_accessor :sendmail_settings 240 248 241 249 @@raise_delivery_errors = true … … 550 558 551 559 def perform_delivery_sendmail(mail) 552 IO.popen(" /usr/sbin/sendmail -i -t","w+") do |sm|560 IO.popen("#{sendmail_settings[:location]} #{sendmail_settings[:arguments]}","w+") do |sm| 553 561 sm.print(mail.encoded.gsub(/\r/, '')) 554 562 sm.flush