You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: chef-repo/cookbooks/2016-security-guide/templates/default/monitrc.erb
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -83,7 +83,7 @@
83
83
#
84
84
# 2016-SECURITY-SCRIPT ADDITION: Email server configuration
85
85
#
86
-
set mailserver <%=@MONIT_EMAIL_SERVER%> port <%=@MONIT_EMAIL_PORT%><% if defined?(MONIT_EMAIL_USERNAME) && MONIT_EMAIL_USERNAME != ''%>username "<%=@MONIT_EMAIL_USERNAME%>"<% end %><% if defined?(MONIT_EMAIL_PASSWORD) && MONIT_EMAIL_PASSWORD != ''%>password "<%=@MONIT_EMAIL_PASSWORD%>"<% end %><% if defined?(MONIT_EMAIL_ENCRYPTION) && MONIT_EMAIL_ENCRYPTION != ''%><%=@MONIT_EMAIL_ENCRYPTION%><% end %>
86
+
set mailserver <%=node['security_guide']['monit']['email_server']%> port <%=node['security_guide']['monit']['email_port']%><% if node['security_guide']['monit'].attribute?('email_username')%>username "<%=node['security_guide']['monit']['email_username']%>"<% end %><% if node['security_guide']['monit'].attribute?('email_password')%>password "<%=node['security_guide']['monit']['email_password']%>"<% end %><% if node['security_guide']['monit'].attribute?('email_encryption')%><%=node['security_guide']['monit']['email_encryption']%><% end %>
87
87
88
88
# backup.bar.baz port 10025, # backup mailserver on port 10025
89
89
# localhost # fallback relay
@@ -166,7 +166,7 @@ set mailserver <%= @MONIT_EMAIL_SERVER %> port <%= @MONIT_EMAIL_PORT %> <% if de
166
166
#
167
167
# 2016-SECURITY-SCRIPT ADDITION: Set alert email address
168
168
#
169
-
set alert <%=@MONIT_ALERT_EMAIL%> not on { instance, action }
169
+
set alert <%=node['security_guide']['monit']['alert_email']%> not on { instance, action }
0 commit comments