Created
August 14, 2017 09:42
-
-
Save nitanka/96796fc6f1f9e68b5ab00592f2329dca to your computer and use it in GitHub Desktop.
Ansible: Installing postfix
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- name: Installing postfix | |
hosts: localhost | |
sudo: yes | |
tasks: | |
- name: Set Postfix option hostname | |
debconf: name=postifx question="postfix/mailname" value="{{ansible_fqdn}}" vtype="string" | |
- name: Set Postfix option type as internet site | |
debconf: name=postfix question="postfix/main_mailer_type" value="'Internet Site'" vtype="string" | |
- name: Install Postfix | |
apt: package={{ item }} state=installed force=yes update_cache=yes cache_valid_time=3600 | |
with_items: | |
- postfix | |
- mailutils |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Initial commit, need to test it more