-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix cpan/backpan mirrors to be up when app is down
This also adds appropriate tasks to start/stop maintenance mode. Refs cpan-testers/cpantesters-project#17
- Loading branch information
Showing
8 changed files
with
173 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
|
||
# This config file shows a maintenance site as a default virtual host. | ||
# This file must come first in alphabetical order. | ||
|
||
NameVirtualHost *:80 | ||
<VirtualHost *:80> | ||
ServerAdmin [email protected] | ||
DocumentRoot /var/www/maintenance | ||
|
||
ErrorLog ${APACHE_LOG_DIR}/error.log | ||
CustomLog ${APACHE_LOG_DIR}/access.log combined | ||
</VirtualHost> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
|
||
# This backpan site is used by neilb's CPAN reports | ||
# (http://neilb.org/cpan-regulars/) | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName backpan.cpantesters.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /home/ftp/BACKPAN | ||
<Directory /home/ftp/BACKPAN> | ||
Options +Indexes | ||
Require all granted | ||
</Directory> | ||
|
||
# Disable CGI scripts | ||
RemoveHandler .cgi .pl | ||
|
||
ErrorLog /var/www/logs/backpan-error.log | ||
CustomLog /var/www/logs/backpan-access.log combined | ||
</VirtualHost> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName cpan.cpantesters.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /home/ftp/CPAN | ||
<Directory /home/ftp/CPAN> | ||
Options +Indexes | ||
Require all granted | ||
</Directory> | ||
|
||
# Disable CGI scripts | ||
RemoveHandler .cgi .pl | ||
|
||
ErrorLog /var/www/logs/cpan-error.log | ||
CustomLog /var/www/logs/cpan-access.log combined | ||
</VirtualHost> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,7 @@ | ||
#NameVirtualHost 212.110.173.51 | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName cpan.cpantesters.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /home/ftp/CPAN | ||
<Directory /home/ftp/CPAN> | ||
Options +Indexes | ||
Require all granted | ||
</Directory> | ||
|
||
# Disable CGI scripts | ||
RemoveHandler .cgi .pl | ||
|
||
ErrorLog /var/www/logs/cpan-error.log | ||
CustomLog /var/www/logs/cpan-access.log combined | ||
</VirtualHost> | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName backpan.cpantesters.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /home/ftp/BACKPAN | ||
<Directory /home/ftp/BACKPAN> | ||
Options +Indexes | ||
Require all granted | ||
</Directory> | ||
|
||
# Disable CGI scripts | ||
RemoveHandler .cgi .pl | ||
|
||
ErrorLog /var/www/logs/backpan-error.log | ||
CustomLog /var/www/logs/backpan-access.log combined | ||
</VirtualHost> | ||
# This config file contains all the sites for the CPAN Testers | ||
# application. Disabling this config will disable CPAN Testers (like, | ||
# for scheduled maintenance) | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName pass.cpantesters.org | ||
|
@@ -146,13 +117,50 @@ | |
CustomLog /var/www/logs/reports-access.log combined | ||
</VirtualHost> | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName test.cpantesters.org | ||
ServerAlias *.cpantesters.org | ||
<VirtualHost 212.110.173.51:443> | ||
ServerName prefs.cpantesters.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /var/www/downtime | ||
DocumentRoot /var/www/cpanprefs/html | ||
|
||
ErrorLog /var/www/logs/downtime-error.log | ||
CustomLog /var/www/logs/downtime-access.log combined | ||
SSLEngine on | ||
SSLCertificateFile /etc/apache2/ssl/prefs/prefs_cpantesters_org.crt | ||
SSLCertificateKeyFile /etc/apache2/ssl/prefs/prefs.cpantesters.org.key | ||
SSLCertificateChainFile /etc/apache2/ssl/prefs/prefs.cpantesters.org.ca-bundle | ||
|
||
RewriteEngine on | ||
RewriteRule ^.*(php)$ /cgi-bin/pages.cgi?act=error-badcmd [PT] | ||
RewriteRule ^/?$ /cgi-bin/pages.cgi [PT] | ||
ScriptAlias /cgi-bin/ /var/www/cpanprefs/cgi-bin/ | ||
Options +ExecCGI | ||
ErrorLog /var/www/logs/cpanprefs-error.log | ||
CustomLog /var/www/logs/cpanprefs-access.log combined | ||
</VirtualHost> | ||
|
||
<VirtualHost 212.110.173.51:443> | ||
ServerName admin.cpantesters.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /var/www/cpanadmin/html | ||
|
||
SSLEngine on | ||
SSLCertificateFile /etc/apache2/ssl/admin/admin_cpantesters_org.crt | ||
SSLCertificateKeyFile /etc/apache2/ssl/admin/admin.cpantesters.org.key | ||
SSLCertificateChainFile /etc/apache2/ssl/admin/admin.cpantesters.org.ca-bundle | ||
|
||
RewriteEngine on | ||
RewriteRule ^.*(php)$ /cgi-bin/pages.cgi?act=error-badcmd [PT] | ||
RewriteRule ^/?$ /cgi-bin/pages.cgi [PT] | ||
|
||
RewriteRule ^/author/testers$ /cgi-bin/pages.cgi?act=author-testers [PT] | ||
RewriteRule ^/author/testers/(.*)$ /cgi-bin/pages.cgi?act=author-testers&letter=$1 [PT] | ||
RewriteRule ^/author/tester/(\d+)$ /cgi-bin/pages.cgi?act=author-tester&testerid=$1 [PT] | ||
RewriteRule ^/author/tester/(\d+)/(prev|next)/(.*)$ /cgi-bin/pages.cgi?act=author-tester&testerid=$1&$2=$3 [PT] | ||
RewriteRule ^/tester/edit$ /cgi-bin/pages.cgi?act=tester-edit&%{QUERY_STRING} [PT] | ||
RewriteRule ^/(tester|user)(-confirm)/(.*)$ /cgi-bin/pages.cgi?act=$1$2&code=$3 [PT] | ||
RewriteRule ^/([a-z]+)\-([a-z]+)/?$ /cgi-bin/pages.cgi?act=$1-$2 [PT] | ||
|
||
ScriptAlias /cgi-bin/ /var/www/cpanadmin/cgi-bin/ | ||
Options +ExecCGI | ||
ErrorLog /var/www/logs/cpanadmin-error.log | ||
CustomLog /var/www/logs/cpanadmin-access.log combined | ||
</VirtualHost> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#NameVirtualHost 212.110.173.51:80 | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName cpantesters.perl.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /var/www/downtime | ||
|
||
RedirectMatch permanent .* http://static.cpantesters.org | ||
|
||
ErrorLog /var/www/logs/perlorg-error.log | ||
CustomLog /var/www/logs/perlorg-access.log combined | ||
</VirtualHost> | ||
|
||
<VirtualHost 212.110.173.51:80> | ||
ServerName testers.cpan.org | ||
ServerAdmin [email protected] | ||
DocumentRoot /var/www/downtime | ||
|
||
RedirectMatch permanent .* http://static.cpantesters.org | ||
|
||
ErrorLog /var/www/logs/cpanorg-error.log | ||
CustomLog /var/www/logs/cpanorg-access.log combined | ||
</VirtualHost> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
|
||
<h1>Down for Maintenance</h1> | ||
|
||
<p>CPAN Testers is temporarily down for maintenance: The database tables | ||
are being repaired. We hope to be back up by Saturday, October 22 | ||
2016.</p> |