Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms


postfix-dovecot (9) Versions 0.2.0

Installs and configures a mail server using Postfix, Dovecot, PostfixAdmin and SpamAssassin, including Amazon SES support.

cookbook 'postfix-dovecot', '= 0.2.0'
cookbook 'postfix-dovecot', '= 0.2.0', :supermarket
knife supermarket install postfix-dovecot
knife supermarket download postfix-dovecot
Quality -%


Installs and configures a mail server using Postfix, Dovecot, PostfixAdmin and SpamAssassin, including Amazon SES support.



This cookbook has been tested on the following platforms:

  • CentOS >= 6.0
  • Debian >= 7.0
  • Ubuntu >= 12.04

Let me know if you use it successfully on any other platform.



  • Dovecot >= 2: requires this version of dovecot to be available by the distribution's package manager.


<table> <tr> <th>Attribute</th> <th>Description</th> <th>Default</th> </tr> <tr> <td><code>node['postfix-dovecot']['postmaster_address']</code></td> <td>Postmaster mail address.</td> <td><code>""</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['hostname']</code></td> <td>Hostname.</td> <td><code>node["fqdn"]</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['sieve']['enabled']</code></td> <td>Whether to enable sieve.</td> <td><code>true</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['sieve']['global_path']</code></td> <td>Sieve global path.</td> <td><code>"#{default["dovecot"]["conf_path"]}/sieve/default.sieve"</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['spamc']['enabled']</code></td> <td>Whether to enable SpamAssassin</td> <td><code>true</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['spamc']['recipe']</code></td> <td>Spamc recipe name to use.</td> <td><code>"onddo-spamassassin"</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['vmail']['user']</code></td> <td>Virtual mail system user name.</td> <td><code>"vmail"</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['vmail']['group']</code></td> <td>Virtual mail system group name.</td> <td><code>node["postfix-dovecot"]["vmail"]["user"]</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['vmail']['uid']</code></td> <td>Virtual mail system user id.</td> <td><code>5000</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['vmail']['gid']</code></td> <td>Virtual mail system group id.</td> <td><code>node["postfix-dovecot"]["vmail"]["uid"]</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['vmail']['home']</code></td> <td>Virtual mail user home path.</td> <td><code>"/var/vmail"</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['ses']['enabled']</code></td> <td>Whether to enable <a href="">Amazon SES</a>.</td> <td><code>false</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['ses']['username']</code></td> <td>Amazon SES SMTP username. See the <a href=""><em>Obtaining Your Amazon SES SMTP Credentials</em> documentation</a>.</td> <td><code>"USERNAME"</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['ses']['password']</code></td> <td>Amazon SES SMTP password.</td> <td><code>"PASSWORD"</code></td> </tr> <tr> <td><code>node['postfix-dovecot']['ses']['servers']</code></td> <td>Amazon SES SMTP servers.</td> <td><code>[<br/>   '',<br/>   ''<br/> ]</code></td> </tr> </table>



Installs and configures everything.


Creates vmail user.


Installs and configures SpamAssassin.


Installs and configures Postfix.


Installs and configures PostfixAdmin.


Installs and configures Dovecot 2.

Usage Example

Including in a Cookbook Recipe

Running it from a recipe:

node['postfix-dovecot']['postmaster_address'] = ''
node['postfix-dovecot']['hostname'] = ''

include_recipe 'postfix-dovecot::default'

postfixadmin_admin '' do
  password 'sup3r-s3cr3t-p4ss'
  action :create

postfixadmin_domain '' do
  login_username ''
  login_password 'sup3r-s3cr3t-p4ss'

postfixadmin_mailbox '' do
  password 'alice'
  login_username ''
  login_password 'sup3r-s3cr3t-p4ss'

postfixadmin_alias '' do
  goto ''
  login_username ''
  login_password 'sup3r-s3cr3t-p4ss'

Don't forget to include the postfix-dovecot cookbook as a dependency in the metadata.

# metadata.rb

depends 'postfix-dovecot'

Including in the Run List

Another alternative is to include the default recipe in your Run List.

  "name": "",
  "run_list": [



  • vagrant
  • berkshelf >= 1.4.0
  • test-kitchen >= 1.0.0.alpha
  • kitchen-vagrant >= 0.10.0

Running the tests

$ kitchen test
$ kitchen verify

Amazon SES Tests

Use the .kitchen.local.yml.example file as a template to see how to run the SES tests.


  1. Fork the repository on Github
  2. Create a named feature branch (like add_component_x)
  3. Write you change
  4. Write tests for your change (if applicable)
  5. Run the tests, ensuring they all pass
  6. Submit a Pull Request using Github

License and Author

Author: Xabier de Zuazo (
Copyright: Copyright (c) 2013 Onddo Labs, SL. (
License: Apache License, Version 2.0

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Dependent cookbooks

postfix-full >= 0.0.0
postfixadmin >= 0.0.0
onddo-spamassassin >= 0.0.0
dovecot >= 0.0.0

Contingent cookbooks

There are no cookbooks that are contingent upon this one.

No quality metric results found