Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inline Apache web server configuration into the application install scripts. #1762

Merged
merged 7 commits into from
Aug 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
set -e

sudo yum -y install httpd
(cd /etc/httpd/conf.d/ && sudo curl -O https://raw.githubusercontent.com/Stackdriver/stackdriver-agent-service-configs/master/etc/httpd/conf.d/status.conf)
sudo mkdir -p /etc/httpd/conf.d/
sudo tee /etc/httpd/conf.d/status.conf >/dev/null <<EOF
ExtendedStatus on
<VirtualHost 127.0.0.1:80>
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
</VirtualHost>
EOF

sudo service httpd start
sleep 2
curl http://localhost:80/server-status?auto
igorpeshansky marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@ set -e

sudo apt update
sudo apt install -y apache2
(cd /etc/apache2/conf-available/ && sudo curl -O https://raw.githubusercontent.com/Stackdriver/stackdriver-agent-service-configs/master/etc/httpd/conf.d/status.conf)
sudo mkdir -p /etc/apache2/conf-available/
sudo tee /etc/apache2/conf-available/status.conf >/dev/null <<EOF
ExtendedStatus on
<VirtualHost 127.0.0.1:80>
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
</VirtualHost>
EOF

sudo service apache2 start
sleep 2
curl http://localhost:80/server-status?auto
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,21 @@ sudo zypper -n refresh

sudo zypper -n install apache2

(cd /etc/apache2/conf.d/ && sudo curl -O https://raw.githubusercontent.com/Stackdriver/stackdriver-agent-service-configs/master/etc/httpd/conf.d/status.conf)
sudo mkdir -p /etc/apache2/conf.d/
sudo tee /etc/apache2/conf.d/status.conf >/dev/null <<EOF
ExtendedStatus on
<VirtualHost 127.0.0.1:80>
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>
</VirtualHost>
EOF
sudo a2enmod mod_status
sudo a2enmod mod_access_compat

sudo service apache2 start
sleep 2
curl http://localhost:80/server-status?auto
Loading