#68 -Properly handle binding to loopback on mixed IPV4/IPV6 systems

Signed-off-by: Sean OMeara <someara@opscode.com>
This commit is contained in:
Tim Smith 2014-06-11 14:04:34 -04:00 committed by Sean OMeara
parent e4c9b11039
commit e6b58b270b
10 changed files with 21 additions and 20 deletions

View File

@ -39,7 +39,7 @@ This change in namespace to `node['postfix']['main']` should allow for greater f
* `node['postfix']['main']['myhostname']` - defaults to fqdn from Ohai
* `node['postfix']['main']['mydomain']` - defaults to domain from Ohai
* `node['postfix']['main']['myorigin']` - defaults to $myhostname
* `node['postfix']['main']['mynetworks']` - default is `127.0.0.0/8`
* `node['postfix']['main']['mynetworks']` - default is nil, which forces Postfix to default to loopback addresses.
* `node['postfix']['main']['inet_interfaces']` - set to `loopback-only`, or `all` for server recipe
* `node['postfix']['main']['alias_maps']` - set to `hash:/etc/aliases`
* `node['postfix']['main']['mailbox_size_limit']` - set to `0` (disabled)
@ -250,10 +250,10 @@ override_attributes(
License & Authors
-----------------
- Author:: Joshua Timberman <joshua@opscode.com>
- Author:: Joshua Timberman <joshua@getchef.com>
```text
Copyright:: 2009-2012, Opscode, Inc
Copyright:: 2009-2014, Chef Software, Inc
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.

View File

@ -1,6 +1,6 @@
# encoding: utf-8
# Author:: Joshua Timberman <joshua@opscode.com>
# Copyright:: Copyright (c) 2009, Opscode, Inc.
# Author:: Joshua Timberman <joshua@getchef.com>
# Copyright:: Copyright 2009-2014, Chef Software, Inc.
# License:: Apache License, Version 2.0
#
# Licensed under the Apache License, Version 2.0 (the "License");
@ -64,7 +64,7 @@ default['postfix']['main']['transport_maps'] = [ "hash:#{node['postfix']['transp
default['postfix']['main']['access_maps'] = ["hash:#{node['postfix']['access_db']}"]
default['postfix']['main']['mailbox_size_limit'] = 0
default['postfix']['main']['smtp_sasl_auth_enable'] = 'no'
default['postfix']['main']['mynetworks'] = '127.0.0.0/8'
default['postfix']['main']['mynetworks'] = nil
default['postfix']['main']['inet_interfaces'] = 'loopback-only'
# Conditional attributes

View File

@ -1,5 +1,5 @@
# encoding: utf-8
# Copyright 2012, Opscode, Inc.
# Copyright 2012-2014, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.

View File

@ -1,8 +1,8 @@
# encoding: utf-8
name 'postfix'
description 'Installs and configures postfix for client or outbound relayhost, or to do SASL auth'
maintainer 'Opscode, Inc.'
maintainer_email 'cookbooks@opscode.com'
maintainer 'Chef Software, Inc.'
maintainer_email 'cookbooks@getchef.com'
license 'Apache 2.0'
version '3.2.1'
recipe 'postfix', 'Installs and configures postfix'

View File

@ -1,5 +1,5 @@
# encoding: utf-8
# Copyright:: Copyright (c) 2012, Opscode, Inc.
# Copyright:: Copyright 2012-2014, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.

View File

@ -1,9 +1,9 @@
# encoding: utf-8
# Author:: Joshua Timberman(<joshua@opscode.com>)
# Author:: Joshua Timberman(<joshua@getchef.com>)
# Cookbook Name:: postfix
# Recipe:: client
#
# Copyright 2009-2012, Opscode, Inc.
# Copyright 2009-2014, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.

View File

@ -1,9 +1,9 @@
# encoding: utf-8
# Author:: Joshua Timberman(<joshua@opscode.com>)
# Author:: Joshua Timberman(<joshua@getchef.com>)
# Cookbook Name:: postfix
# Recipe:: default
#
# Copyright 2009-2012, Opscode, Inc.
# Copyright 2009-2014, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@ -59,7 +59,7 @@ when 'omnios'
source 'manifest-postfix.xml.erb'
owner 'root'
group 'root'
mode 00644
mode '0644'
notifies :run, 'execute[load postfix manifest]', :immediately
end
@ -113,7 +113,7 @@ end
source "#{cfg}.cf.erb"
owner 'root'
group 0
mode 00644
mode '0644'
notifies :restart, 'service[postfix]'
variables(settings: node['postfix'][cfg])
cookbook node['postfix']["#{cfg}_template_source"]

View File

@ -1,10 +1,10 @@
# encoding: utf-8
#
# Author:: Joshua Timberman(<joshua@opscode.com>)
# Author:: Joshua Timberman(<joshua@getchef.com>)
# Cookbook Name:: postfix
# Recipe:: sasl_auth
#
# Copyright 2009, Opscode, Inc.
# Copyright 2009-2014, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.

View File

@ -1,10 +1,10 @@
# encoding: utf-8
#
# Author:: Joshua Timberman(<joshua@opscode.com>)
# Author:: Joshua Timberman(<joshua@getchef.com>)
# Cookbook Name:: postfix
# Recipe:: server
#
# Copyright 2009-2012, Opscode, Inc.
# Copyright 2009-2014, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.

View File

@ -4,6 +4,7 @@
###
<% @settings.sort.map do |key, value| -%>
<% next if value.nil? -%>
<% if value.kind_of? Array -%>
<%= "#{key} = #{value.join(', ')}"%>
<% else -%>