Merge pull request #9636 from Wachizungu/fix-rhel-httpd-listen-config

fix: [doc:rhel-installer] Correct conditional addition of httpd Liste…
pull/9637/head
Alexandre Dulaunoy 2024-03-24 12:19:27 +01:00 committed by GitHub
commit 3e4738adeb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 2 deletions

View File

@ -411,7 +411,9 @@ apacheConfig_RHEL7 () {
#sudo sed -i "s/SetHandler/\#SetHandler/g" /etc/httpd/conf.d/misp.ssl.conf
sudo rm /etc/httpd/conf.d/ssl.conf
sudo chmod 644 /etc/httpd/conf.d/misp.ssl.conf
sudo sed -i '/Listen 443/!s/Listen 80/a Listen 443/' /etc/httpd/conf/httpd.conf
if ! grep -x "Listen 443" /etc/httpd/conf/httpd.conf; then
sudo sed -i '/Listen 80/a Listen 443' /etc/httpd/conf/httpd.conf
fi
# If a valid SSL certificate is not already created for the server, create a self-signed certificate:
echo "The Common Name used below will be: ${OPENSSL_CN}"

View File

@ -452,7 +452,9 @@ apacheConfig_RHEL8 () {
#sudo sed -i "s/SetHandler/\#SetHandler/g" /etc/httpd/conf.d/misp.ssl.conf
sudo rm /etc/httpd/conf.d/ssl.conf
sudo chmod 644 /etc/httpd/conf.d/misp.ssl.conf
sudo sed -i '/Listen 443/!s/Listen 80/a Listen 443/' /etc/httpd/conf/httpd.conf
if ! grep -x "Listen 443" /etc/httpd/conf/httpd.conf; then
sudo sed -i '/Listen 80/a Listen 443' /etc/httpd/conf/httpd.conf
fi
# If a valid SSL certificate is not already created for the server, create a self-signed certificate:
echo "The Common Name used below will be: ${OPENSSL_CN}"