Commit 19772d95 authored by drumm's avatar drumm Committed by Neil Drumm

Cluster verify restarts all clustered servers.

parent 0688852e
......@@ -76,7 +76,7 @@ class provisionService_http_apache extends provisionService_http {
function parse_configs() {
// This is required to be configurable, due to the fact that different
// hosts might need to do this differently.
if (d()->service('http')->server()->shell_exec($this->restart_cmd)) {
if ($this->server()->shell_exec($this->restart_cmd)) {
drush_log(dt('Apache has been restarted'));
}
else {
......
<?php
class provisionService_http_cluster extends provisionService_http {
private $servers = array();
static function option_documentation() {
return array(
'--cluster_web_servers' => 'server with cluster: comma-separated list of web servers.'
......@@ -9,5 +11,18 @@ class provisionService_http_cluster extends provisionService_http {
function init() {
$this->setProperty('cluster_web_servers', array(), TRUE);
foreach ($this->cluster_web_servers as $server) {
$this->servers[] = d($server);
}
}
function verify() {
$this->parse_configs();
}
function parse_configs() {
foreach ($this->servers as $server) {
$server->service('http')->parse_configs();
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment