From: Maxious Date: Thu, 21 Apr 2011 12:25:39 +0000 Subject: Add new service_id for complete network shutdown X-Git-Url: https://maxious.lambdacomplex.org/git/?p=busui.git&a=commitdiff&h=9fe49caf6e9f1c3c080d1cdbd6bdd026bca490e1 --- Add new service_id for complete network shutdown --- --- a/aws/awsStartup.sh +++ b/aws/awsStartup.sh @@ -11,6 +11,8 @@ chcon -R -h root:object_r:httpd_sys_content_t /var/www/* chcon -R -t httpd_sys_content_rw_t /var/www/lib/staticmaplite/cache chmod -R 777 /var/www/lib/staticmaplite/cache +chcon -R -t httpd_sys_content_rw_t /var/www/labs/tiles +chmod -R 777 /var/www/labs/tiles wget http://s3-ap-southeast-1.amazonaws.com/busresources/cbrfeed.zip \ -O /var/www/cbrfeed.zip --- a/include/common-net.inc.php +++ b/include/common-net.inc.php @@ -5,7 +5,7 @@ $ch = curl_init($url); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_HEADER, 0); - curl_setopt($ch, CURLOPT_TIMEOUT, 30); + curl_setopt($ch, CURLOPT_TIMEOUT, 45); $page = curl_exec($ch); if (curl_errno($ch)) { echo " Database temporarily unavailable: "; --- a/include/common-template.inc.php +++ b/include/common-template.inc.php @@ -191,8 +191,13 @@ if (!$_SESSION['service_id']) { $overrides = getServiceOverride(); if ($overrides['service_id']){ +if ($overrides['service_id'] == "noservice") { + echo '
Buses are not running today due to industrial action/public holiday. See http://www.action.act.gov.au for details.
'; + } else { echo '
Buses are running on an altered timetable today due to industrial action/public holiday. See http://www.action.act.gov.au for details.
'; - } + } + } } } } --- a/readme.txt +++ b/readme.txt @@ -18,6 +18,16 @@ End with a backslash and a period on a line by itself. >> saturday 20110416 2 >> sunday 20110416 1 +>> saturday 20110423 2 +>> sunday 20110423 1 +>> weekday 20110425 2 +>> sunday 20110425 1 +>> weekday 20110422 2 +>> noservice 20110422 1 +>> weekday 20110426 2 +>> noservice 20110426 1 +>> sunday 20110424 2 +>> noservice 20110424 1 >> \.