reversing steps to create cert
This commit is contained in:
@@ -1,2 +1,2 @@
|
||||
certbot certonly -t -n --agree-tos --webroot -w <%= @ng_certbot_cert_path %>/ -d <%= @ng_nagios_server %> --email <%= @ng_mail_user %>
|
||||
certbot certonly -t -n --agree-tos --webroot -w <%= @ng_certbot_cert_path %>/ -d www.<%= @ng_webserver_name %> -d <%= @ng_webserver_name %> --email <%= @ng_mail_user %>
|
||||
touch /etc/httpd/conf.d/.cert_created
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<VirtualHost *:<%= @ng_http_port %>>
|
||||
ServerAdmin root@localhost
|
||||
DocumentRoot /var/www/html
|
||||
ServerName www.<%= @ng_nagios_server %>
|
||||
ServerAlias <%= @ng_nagios_server %>
|
||||
ServerName www.<%= @ng_webserver_name %>
|
||||
ServerAlias <%= @ng_webserver_name %>
|
||||
<% if @ng_use_https == true -%>
|
||||
Redirect permanent / https://<%= @ng_nagios_server %>/nagios
|
||||
Redirect permanent / https://<%= @ng_webserver_name %>/nagios
|
||||
<% end -%>
|
||||
<% if @ng_use_https != true -%>
|
||||
Redirect permanent / http://<%= @ng_nagios_server %>/nagios
|
||||
Redirect permanent / http://<%= @ng_webserver_name %>/nagios
|
||||
<% end -%>
|
||||
<Directory />
|
||||
AllowOverride All
|
||||
</Directory>
|
||||
ErrorLog /var/log/httpd/<%= @ng_nagios_server %>-error_log
|
||||
CustomLog /var/log/httpd/<%= @ng_nagios_server %>-access_log common
|
||||
ErrorLog /var/log/httpd/<%= @ng_webserver_name %>-error_log
|
||||
CustomLog /var/log/httpd/<%= @ng_webserver_name %>-access_log common
|
||||
</VirtualHost>
|
||||
|
||||
Reference in New Issue
Block a user