Skip to content

Commit

Permalink
Merge pull request deis#4290 from aledbf/improve-nginx-status
Browse files Browse the repository at this point in the history
feat(router): improve nginx status page
  • Loading branch information
aledbf committed Aug 18, 2015
2 parents 9b45fe1 + b284dc2 commit d3a333f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 5 additions & 0 deletions router/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ get_src 501f299abdb81b992a980bda182e5de5a4b2b3e275fbf72ee34dd7ae84c4b679 \
get_src 8d280fc083420afb41dbe10df9a8ceec98f1d391bd2caa42ebae67d5bc9295d8 \
"https://github.com/openresty/set-misc-nginx-module/archive/v$VERSION_SETMISC.tar.gz"

# replace with a release instead a commit once e06a618e5780b4b94b21cab37d61820dcd3bb585 is contained in one.
get_src 47340cf0c711b10a0231fca9264d73ea791ff8420b823b0295ae3df2d968a205 \
"https://github.com/vozlt/nginx-module-vts/archive/22c51e201a550bb94e96239fef541347beb4eeca.tar.gz"

# build nginx
cd "$BUILD_PATH/$VERSION_NGINX"

Expand All @@ -88,6 +92,7 @@ cd "$BUILD_PATH/$VERSION_NGINX"
--add-module="$BUILD_PATH/naxsi-$VERSION_NAXSI/naxsi_src" \
--add-module="$BUILD_PATH/ngx_devel_kit-$VERSION_NDK" \
--add-module="$BUILD_PATH/set-misc-nginx-module-$VERSION_SETMISC" \
--add-module="$BUILD_PATH/nginx-module-vts-22c51e201a550bb94e96239fef541347beb4eeca" \
&& make && make install

mv /tmp/firewall /opt/nginx/firewall
6 changes: 4 additions & 2 deletions router/image/templates/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ events {

http {
# basic settings
vhost_traffic_status_zone;

sendfile on;
tcp_nopush on;
tcp_nodelay on;
Expand Down Expand Up @@ -329,8 +331,8 @@ http {
return 200;
}
location /router-nginx-status {
stub_status on;
return 200;
vhost_traffic_status_display;
vhost_traffic_status_display_format html;
}
location / {
return 404;
Expand Down

0 comments on commit d3a333f

Please sign in to comment.