Skip to content

Commit 01194cf

Browse files
committed
Switch Default for Restart-Command to systemctl
Almost all Linux-Distributions now default to Systemd. So switch the Default for Restart-Command to systemctl. - use /usr/bin/systemctl instead of /bin/systemctl, because with usr-Merge the former Dir is dead - keep Alpine and RedHat 6 on init.d
1 parent 1e9eddb commit 01194cf

File tree

5 files changed

+12
-7
lines changed

5 files changed

+12
-7
lines changed

data/common.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ postfix::params::aliasesseltype: ~
33
postfix::params::seltype: ~
44
postfix::params::mailx_package: 'mailx'
55
postfix::params::master_os_template: "postfix/master.cf.default.erb"
6-
postfix::params::restart_cmd: '/etc/init.d/postfix reload'
6+
postfix::params::restart_cmd: '/usr/bin/systemctl reload postfix'
77
...

data/os/Alpine.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
---
22
postfix::params::master_os_template: "postfix/master.cf.debian.erb"
3+
postfix::params::restart_cmd: '/etc/init.d/postfix reload'

data/osfamily/RedHat.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
---
22
postfix::params::aliasesseltype: 'etc_aliases_t'
33
postfix::params::seltype: 'postfix_etc_t'
4-
postfix::params::restart_cmd: '/bin/systemctl reload postfix'
54
postfix::params::master_os_template: 'postfix/master.cf.redhat.erb'
65
postfix::mta_bin_path: '/usr/sbin/sendmail.postfix'
76
...

data/osfamily/RedHat/6.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
3+
postfix::params::mailx_package: 's-nail'
4+
postfix::ldap_packages: ['postfix-ldap']
5+
postfix::params::restart_cmd: '/etc/init.d/postfix reload'

spec/classes/postfix_spec.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@
8484
ensure: 'running',
8585
enable: 'true',
8686
hasstatus: 'true',
87-
restart: '/etc/init.d/postfix reload'
87+
restart: '/usr/bin/systemctl reload postfix'
8888
)
8989
}
9090
end
@@ -111,7 +111,7 @@
111111
ensure: 'running',
112112
enable: 'true',
113113
hasstatus: 'true',
114-
restart: '/bin/systemctl reload postfix'
114+
restart: '/usr/bin/systemctl reload postfix'
115115
)
116116
}
117117
end
@@ -124,7 +124,7 @@
124124
ensure: 'running',
125125
enable: 'true',
126126
hasstatus: 'true',
127-
restart: '/bin/systemctl reload postfix'
127+
restart: '/usr/bin/systemctl reload postfix'
128128
)
129129
}
130130
end
@@ -151,7 +151,7 @@
151151
ensure: 'running',
152152
enable: 'true',
153153
hasstatus: 'true',
154-
restart: '/bin/systemctl reload postfix'
154+
restart: '/usr/bin/systemctl reload postfix'
155155
)
156156
}
157157
end
@@ -234,7 +234,7 @@
234234
ensure: 'running',
235235
enable: 'true',
236236
hasstatus: 'true',
237-
restart: '/etc/init.d/postfix reload'
237+
restart: '/usr/bin/systemctl reload postfix'
238238
)
239239
}
240240

0 commit comments

Comments
 (0)