mirror of
https://github.com/idanoo/php-resque.git
synced 2024-11-21 16:01:53 +00:00
gethostname() doesn't work on Amazon's EC2
This commit is contained in:
parent
c335bc3555
commit
7101a3097f
@ -69,13 +69,8 @@ class Resque_Worker
|
||||
}
|
||||
|
||||
$this->queues = $queues;
|
||||
if(function_exists('gethostname')) {
|
||||
$hostname = gethostname();
|
||||
}
|
||||
else {
|
||||
$hostname = php_uname('n');
|
||||
}
|
||||
$this->hostname = $hostname;
|
||||
$this->hostname = php_uname('n');
|
||||
|
||||
$this->id = $this->hostname . ':'.getmypid() . ':' . implode(',', $this->queues);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user