diff options
-rw-r--r-- | Bugzilla/DaemonControl.pm | 3 | ||||
-rw-r--r-- | Bugzilla/Quantum.pm | 7 | ||||
-rw-r--r-- | Bugzilla/Quantum/Static.pm | 4 | ||||
-rw-r--r-- | Dockerfile | 1 | ||||
-rwxr-xr-x | scripts/bugzilla_quantum | 7 |
5 files changed, 15 insertions, 7 deletions
diff --git a/Bugzilla/DaemonControl.pm b/Bugzilla/DaemonControl.pm index 2c6df1b87..43461b5ec 100644 --- a/Bugzilla/DaemonControl.pm +++ b/Bugzilla/DaemonControl.pm @@ -103,7 +103,8 @@ sub run_httpd { # we have to setsid() to make a new process group # or else apache will kill its parent. setsid(); - my @command = ( HTTPD_BIN, '-DFOREGROUND', '-f' => HTTPD_CONFIG, @args ); + warn "ignoring args: @args"; + my @command = ( $^X, '/app/scripts/bugzilla_quantum', 'daemon', "--listen=http://*:$ENV{PORT}" ); exec @command or die "failed to exec $command[0] $!"; }, diff --git a/Bugzilla/Quantum.pm b/Bugzilla/Quantum.pm index 7cfed59c6..7270ada55 100644 --- a/Bugzilla/Quantum.pm +++ b/Bugzilla/Quantum.pm @@ -66,6 +66,13 @@ rewrite => 1, $r->any('/')->to('Legacy#index_cgi'); + $r->get( + '/__lbheartbeat__' => sub { + my $c = shift; + $c->reply->file($c->app->home->child('__lbheartbeat__')); + }, + ); + my $urlbase = Bugzilla->localconfig->{urlbase}; $r->get( '/quicksearch.html' => sub { diff --git a/Bugzilla/Quantum/Static.pm b/Bugzilla/Quantum/Static.pm index 2a4ed1988..2bd0555e2 100644 --- a/Bugzilla/Quantum/Static.pm +++ b/Bugzilla/Quantum/Static.pm @@ -24,9 +24,9 @@ sub file { return $self->SUPER::file($legacy_rel); } else { - warn "legacy $rel\n"; + warn "mojo $rel\n"; return $self->SUPER::file($rel); } } -1;
\ No newline at end of file +1; diff --git a/Dockerfile b/Dockerfile index d2da33866..847fb0a69 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,7 +17,6 @@ ENV HTTPD_MaxClients=256 ENV HTTPD_MaxRequestsPerChild=4000 ENV PORT=8000 -ENV MOJO_LISTEN http://*:$PORT # we run a loopback logging server on this TCP port. ENV LOGGING_PORT=5880 diff --git a/scripts/bugzilla_quantum b/scripts/bugzilla_quantum index 1112faabd..9069a2f05 100755 --- a/scripts/bugzilla_quantum +++ b/scripts/bugzilla_quantum @@ -4,14 +4,15 @@ use strict; use warnings; use File::Basename qw(basename dirname); -use File::Spec::Functions qw(catdir rel2abs); +use File::Spec::Functions qw(catdir); +use Cwd qw(realpath); BEGIN { require lib; - my $dir = rel2abs( catdir(dirname(__FILE__), '..') ); + my $dir = realpath( catdir(dirname(__FILE__), '..') ); lib->import( $dir, catdir( $dir, 'lib' ), catdir( $dir, qw(local lib perl5) ) ); } use Mojolicious::Commands; # Start command line interface for application -Mojolicious::Commands->start_app('Bugzilla::Quantum');
\ No newline at end of file +Mojolicious::Commands->start_app('Bugzilla::Quantum'); |