Home

Awesome

Nginx virtual host traffic status module

CI License

Nginx virtual host traffic status module

Table of Contents

Version

GitHub Release

See the GitHub Releases for the latest tagged release.

Test

Run sudo prove -r t after you have installed this module. The sudo is required because the test requires Nginx to listen on port 80.

Dependencies

Compatibility

Earlier versions is not tested.

Screenshots

screenshot-vts-0


screenshot-vts-1

Installation

  1. Clone the git repository.
shell> git clone git://github.com/vozlt/nginx-module-vts.git
  1. Add the module to the build configuration by adding --add-module=/path/to/nginx-module-vts

  2. Build the nginx binary.

  3. Install the nginx binary.

Synopsis

http {
    vhost_traffic_status_zone;

    ...

    server {

        ...

        location /status {
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

Description

This is an Nginx module that provides access to virtual host status information. It contains the current status such as servers, upstreams, caches. This is similar to the live activity monitoring of nginx plus. The built-in html is also taken from the demo page of old version.

First of all, the directive vhost_traffic_status_zone is required, and then if the directive vhost_traffic_status_display is set, can be access to as follows:

JSON document contains as follows:

{
    "hostName": ...,
    "moduleVersion": ...,
    "nginxVersion": ...,
    "loadMsec": ...,
    "nowMsec": ...,
    "connections": {
        "active":...,
        "reading":...,
        "writing":...,
        "waiting":...,
        "accepted":...,
        "handled":...,
        "requests":...
    },
    "sharedZones": {
        "name":...,
        "maxSize":...,
        "usedSize":...,
        "usedNode":...
    },
    "serverZones": {
        "...":{
            "requestCounter":...,
            "inBytes":...,
            "outBytes":...,
            "responses":{
                "1xx":...,
                "2xx":...,
                "3xx":...,
                "4xx":...,
                "5xx":...,
                "miss":...,
                "bypass":...,
                "expired":...,
                "stale":...,
                "updating":...,
                "revalidated":...,
                "hit":...,
                "scarce":...
            },
            "requestMsecCounter":...,
            "requestMsec":...,
            "requestMsecs":{
                "times":[...],
                "msecs":[...]
            },
            "requestBuckets":{
                "msecs":[...],
                "counters":[...]
            },
        }
        ...
    },
    "filterZones": {
        "...":{
            "...":{
                "requestCounter":...,
                "inBytes":...,
                "outBytes":...,
                "responses":{
                    "1xx":...,
                    "2xx":...,
                    "3xx":...,
                    "4xx":...,
                    "5xx":...,
                    "miss":...,
                    "bypass":...,
                    "expired":...,
                    "stale":...,
                    "updating":...,
                    "revalidated":...,
                    "hit":...,
                    "scarce":...
                },
                "requestMsecCounter":...,
                "requestMsec":...,
                "requestMsecs":{
                    "times":[...],
                    "msecs":[...]
                },
                "requestBuckets":{
                    "msecs":[...],
                    "counters":[...]
                },
            },
            ...
        },
        ...
    },
    "upstreamZones": {
        "...":[
            {
                "server":...,
                "requestCounter":...,
                "inBytes":...,
                "outBytes":...,
                "responses":{
                    "1xx":...,
                    "2xx":...,
                    "3xx":...,
                    "4xx":...,
                    "5xx":...
                },
                "requestMsecCounter":...,
                "requestMsec":...,
                "requestMsecs":{
                    "times":[...],
                    "msecs":[...]
                },
                "requestBuckets":{
                    "msecs":[...],
                    "counters":[...]
                },
                "responseMsecCounter":...,
                "responseMsec":...,
                "responseMsecs":{
                    "times":[...],
                    "msecs":[...]
                },
                "responseBuckets":{
                    "msecs":[...],
                    "counters":[...]
                },
                "weight":...,
                "maxFails":...,
                "failTimeout":...,
                "backup":...,
                "down":...
            }
            ...
        ],
        ...
    }
    "cacheZones": {
        "...":{
            "maxSize":...,
            "usedSize":...,
            "inBytes":...,
            "outBytes":...,
            "responses":{
                "miss":...,
                "bypass":...,
                "expired":...,
                "stale":...,
                "updating":...,
                "revalidated":...,
                "hit":...,
                "scarce":...
            }
        },
        ...
    }
}

The overCounts objects in JSON document are mostly for 32bit system and will be increment by 1 if its value is overflowed. The directive vhost_traffic_status_display_format sets the default ouput format that is one of json, jsonp, html, prometheus. (Default: json)

Traffic calculation as follows:

All calculations are working in log processing phase of Nginx. Internal redirects(X-Accel-Redirect or error_page) does not calculate in the UpstreamZones.

Caveats: this module relies on nginx logging system(NGX_HTTP_LOG_PHASE:last phase of the nginx http), so the traffic may be in certain cirumstances different that real bandwidth traffic. Websocket, canceled downloads may be cause of inaccuracies. The working of the module doesn't matter at all whether the access_log directive "on" or "off". Again, this module works well on "access_log off". When using several domains it sets to be first domain(left) of server_name directive. If you don't want it, see the vhost_traffic_status_filter_by_host, vhost_traffic_status_filter_by_set_key directive.

See the following modules for the stream traffic statistics:

Calculations and Intervals

Averages

All averages are currently calculated as AMM(Arithmetic Mean) over the last 64 values.

Control

It is able to reset or delete traffic zones through a query string. The request responds with a JSON document.

http {

    geoip_country /usr/share/GeoIP/GeoIP.dat;

    vhost_traffic_status_zone;
    vhost_traffic_status_filter_by_set_key $geoip_country_code country::*;

    ...

    server {

        server_name example.org;

        ...

        vhost_traffic_status_filter_by_set_key $geoip_country_code country::$server_name;

        location /status {
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

If it set as above, then the control uri is like example.org/status/control.

The available request arguments are as follows:

To get status of traffic zones on the fly

This is similar to the status/format/json except that it can get each zones.

To get fully zones

To get group zones

The mainZones values are default status values including hostName, moduleVersion, nginxVersion, loadMsec, nowMsec, connections.

To get each zones

To reset traffic zones on the fly

It reset the values of specified zones to 0.

To reset fully zones

To reset group zones

To reset each zones

To delete traffic zones on the fly

It delete the specified zones in shared memory.

To delete fully zones

To delete group zones

To delete each zones

Set

It can get the status values in nginx configuration separately using vhost_traffic_status_set_by_filter directive. It can acquire almost all status values and the obtained value is stored in user-defined-variable which is first argument.

http {

    geoip_country /usr/share/GeoIP/GeoIP.dat;

    vhost_traffic_status_zone;
    vhost_traffic_status_filter_by_set_key $geoip_country_code country::*;

    ...
    upstream backend {
        10.10.10.11:80;
        10.10.10.12:80;
    }

    server {

        server_name example.org;

        ...

        vhost_traffic_status_filter_by_set_key $geoip_country_code country::$server_name;

        vhost_traffic_status_set_by_filter $requestCounter server/example.org/requestCounter;
        vhost_traffic_status_set_by_filter $requestCounterKR filter/country::example.org@KR/requestCounter;

        location /backend {
            vhost_traffic_status_set_by_filter $requestCounterB1 upstream@group/backend@10.10.10.11:80/requestCounter;
            proxy_pass http://backend;
        }
    }
}

The above settings are as follows:

Please see the vhost_traffic_status_set_by_filter directive for detailed usage.

JSON

The following status information is provided in the JSON format:

Json used by status

/{status_uri}/format/json

/{status_uri}/control?cmd=status&...

Json used by control

/{status_uri}/control?cmd=reset&...

/{status_uri}/control?cmd=delete&...

Variables

The following embedded variables are provided:

Limit

It is able to limit total traffic per each host by using the directive vhost_traffic_status_limit_traffic. It also is able to limit all traffic by using the directive vhost_traffic_status_limit_traffic_by_set_key. When the limit is exceeded, the server will return the 503 (Service Temporarily Unavailable) error in reply to a request. The return code can be changeable.

To limit traffic for server

http {

    vhost_traffic_status_zone;

    ...

    server {

        server_name *.example.org;

        vhost_traffic_status_limit_traffic in:64G;
        vhost_traffic_status_limit_traffic out:1024G;

        ...
    }
}

To limit traffic for filter

http {
    geoip_country /usr/share/GeoIP/GeoIP.dat;

    vhost_traffic_status_zone;

    ...

    server {

        server_name example.org;

        vhost_traffic_status_filter_by_set_key $geoip_country_code country::$server_name;
        vhost_traffic_status_limit_traffic_by_set_key FG@country::$server_name@US out:1024G;
        vhost_traffic_status_limit_traffic_by_set_key FG@country::$server_name@CN out:2048G;

        ...

    }
}

To limit traffic for upstream

http {

    vhost_traffic_status_zone;

    ...

    upstream backend {
        server 10.10.10.17:80;
        server 10.10.10.18:80;
    }

    server {

        server_name example.org;

        location /backend {
            vhost_traffic_status_limit_traffic_by_set_key UG@backend@10.10.10.17:80 in:512G;
            vhost_traffic_status_limit_traffic_by_set_key UG@backend@10.10.10.18:80 in:1024G;
            proxy_pass http://backend;
        }

        ...

    }
}

Caveats: Traffic is the cumulative transfer or counter, not a bandwidth.

Use cases

It is able to calculate the user defined individual stats by using the directive vhost_traffic_status_filter_by_set_key.

To calculate traffic for individual country using GeoIP

http {
    geoip_country /usr/share/GeoIP/GeoIP.dat;

    vhost_traffic_status_zone;
    vhost_traffic_status_filter_by_set_key $geoip_country_code country::*;

    ...

    server {

        ...

        vhost_traffic_status_filter_by_set_key $geoip_country_code country::$server_name;

        location /status {
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

Basically, country flags image is built-in in HTML. The country flags image is enabled if the country string is included in group name which is second argument of vhost_traffic_status_filter_by_set_key directive.

To calculate traffic for individual storage volume

http {
    vhost_traffic_status_zone;

    ...

    server {

        ...

        location ~ ^/storage/(.+)/.*$ {
            set $volume $1;
            vhost_traffic_status_filter_by_set_key $volume storage::$server_name;
        }

        location /status {
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

To calculate traffic for individual user agent

http {
    vhost_traffic_status_zone;

    map $http_user_agent $filter_user_agent {
        default 'unknown';
        ~iPhone ios;
        ~Android android;
        ~(MSIE|Mozilla) windows;
    }

    vhost_traffic_status_filter_by_set_key $filter_user_agent agent::*;

    ...

    server {

        ...

        vhost_traffic_status_filter_by_set_key $filter_user_agent agent::$server_name;

        location /status {
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

To calculate traffic for detailed http status code

http {
    vhost_traffic_status_zone;

    server {

        ...

        vhost_traffic_status_filter_by_set_key $status $server_name;

        location /status {
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

Caveats: $status variable is available in nginx-(1.3.2, 1.2.2).

To calculate traffic for dynamic dns

If the domain has multiple DNS A records, you can calculate traffic for individual IPs for the domain using the filter feature or a variable in proxy_pass.

http {
    vhost_traffic_status_zone;

    upstream backend {
        elb.example.org:80;
    }

    ...

    server {

        ...

        location /backend {
            vhost_traffic_status_filter_by_set_key $upstream_addr upstream::backend;
            proxy_pass backend;
        }
    }
}
http {
    vhost_traffic_status_zone;

    resolver 10.10.10.53 valid=10s

    ...

    server {

        ...

        location /backend {
            set $backend_server elb.example.org;
            proxy_pass http://$backend_server;
        }
    }
}

Caveats: Please more details about NGINX DNS see the dns-service-discovery-nginx-plus.

To calculate traffic except for status page

http {
    vhost_traffic_status_zone;

    ...

    server {

        ...

        location /status {
            vhost_traffic_status_bypass_limit on;
            vhost_traffic_status_bypass_stats on;
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

To maintain statistics data permanently

http {
    vhost_traffic_status_zone;
    vhost_traffic_status_dump /var/log/nginx/vts.db;

    ...

    server {

        ...

    }
}

Customizing

To customize after the module installed

  1. You need to change the {{uri}} string to your status uri in status.template.html as follows:
shell> vi share/status.template.html
var vtsStatusURI = "yourStatusUri/format/json", vtsUpdateInterval = 1000;
  1. And then, customizing and copy status.template.html to server root directory as follows:
shell> cp share/status.template.html /usr/share/nginx/html/status.html
  1. Configure nginx.conf
   server {
       server_name example.org;
       root /usr/share/nginx/html;

       # Redirect requests for / to /status.html
       location = / {
           return 301 /status.html;
       }

       location = /status.html {}

       # Everything beginning /status (except for /status.html) is
       # processed by the status handler
       location /status {
           vhost_traffic_status_display;
           vhost_traffic_status_display_format json;
       }
   }

  1. Access to your html.
http://example.org/status.html

To customize before the module installed

  1. Modify share/status.template.html (Do not change {{uri}} string)

  2. Recreate the ngx_http_vhost_traffic_status_module_html.h as follows:

shell> cd util
shell> ./tplToDefine.sh ../share/status.template.html > ../src/ngx_http_vhost_traffic_status_module_html.h
  1. Add the module to the build configuration by adding --add-module=/path/to/nginx-module-vts

  2. Build the nginx binary.

  3. Install the nginx binary.

Directives

draw_io_vts_diagram

vhost_traffic_status

--
Syntaxvhost_traffic_status <on|off>
Defaultoff
Contexthttp, server, location

Description: Enables or disables the module working. If you set vhost_traffic_status_zone directive, is automatically enabled.

vhost_traffic_status_zone

--
Syntaxvhost_traffic_status_zone [shared:name:size]
Defaultshared:vhost_traffic_status:1m
Contexthttp

Description: Sets parameters for a shared memory zone that will keep states for various keys. The cache is shared between all worker processes. In most cases, the shared memory size used by nginx-module-vts does not increase much. The shared memory size is increased pretty when using vhost_traffic_status_filter_by_set_key directive but if filter's keys are fixed(eg. the total number of the country code is about 240) it does not continuously increase.

If you use vhost_traffic_status_filter_by_set_key directive, set it as follows:

vhost_traffic_status_dump

--
Syntaxvhost_traffic_status_dump path [period]
Default-
Contexthttp

Description: Enables the statistics data dump and restore. The path is a location to dump the statistics data.(e.g. /var/log/nginx/vts.db) The period is a backup cycle time.(Default: 60s) It is backed up immediately regardless of the backup cycle if nginx is exited by signal(SIGKILL).

vhost_traffic_status_display

--
Syntaxvhost_traffic_status_display
Default-
Contexthttp, server, location

Description: Enables or disables the module display handler.

vhost_traffic_status_display_format

--
Syntaxvhost_traffic_status_display_format <json|html|jsonp|prometheus>
Defaultjson
Contexthttp, server, location

Description: Sets the display handler's output format. If you set json, will respond with a JSON document. If you set html, will respond with the built-in live dashboard in HTML. If you set jsonp, will respond with a JSONP callback function(default: ngx_http_vhost_traffic_status_jsonp_callback). If you set prometheus, will respond with a prometheus document.

vhost_traffic_status_display_jsonp

--
Syntaxvhost_traffic_status_display_jsonp callback
Defaultngx_http_vhost_traffic_status_jsonp_callback
Contexthttp, server, location

Description: Sets the callback name for the JSONP.

vhost_traffic_status_display_sum_key

--
Syntaxvhost_traffic_status_display_sum_key name
Default*
Contexthttp, server, location

Description: Sets the sum key string in serverZones field's JSON. The default sum key string is the "*".

vhost_traffic_status_filter

--
Syntaxvhost_traffic_status_filter <on|off>
Defaulton
Contexthttp, server, location

Description: Enables or disables the filter features.

vhost_traffic_status_filter_by_host

--
Syntaxvhost_traffic_status_filter_by_host <on|off>
Defaultoff
Contexthttp, server, location

Description: Enables or disables the keys by Host header field. If you set on and nginx's server_name directive set several or wildcard name starting with an asterisk, e.g. “*.example.org” and requested to server with hostname such as (a|b|c).example.org or *.example.org then json serverZones is printed as follows:

server {
  server_name *.example.org;
  vhost_traffic_status_filter_by_host on;

  ...

}
  ...
  "serverZones": {
      "a.example.org": {
      ...
      },
      "b.example.org": {
      ...
      },
      "c.example.org": {
      ...
      }
      ...
   },
   ...

It provides the same function that set vhost_traffic_status_filter_by_set_key $host.

vhost_traffic_status_filter_by_set_key

--
Syntaxvhost_traffic_status_filter_by_set_key key [name]
Default-
Contexthttp, server, location

Description: Enables the keys by user defined variable. The key is a key string to calculate traffic. The name is a group string to calculate traffic. The key and name can contain variables such as $host, $server_name. The name's group belongs to filterZones if specified. The key's group belongs to serverZones if not specified second argument name. The example with geoip module is as follows:

server {
  server_name example.org;
  vhost_traffic_status_filter_by_set_key $geoip_country_code country::$server_name;

  ...

}
  ...
  "serverZones": {
  ...
  },
  "filterZones": {
      "country::example.org": {
          "KR": {
              "requestCounter":...,
              "inBytes":...,
              "outBytes":...,
              "responses":{
                  "1xx":...,
                  "2xx":...,
                  "3xx":...,
                  "4xx":...,
                  "5xx":...,
                  "miss":...,
                  "bypass":...,
                  "expired":...,
                  "stale":...,
                  "updating":...,
                  "revalidated":...,
                  "hit":...,
                  "scarce":...
              },
              "requestMsecCounter":...,
              "requestMsec":...,
              "requestMsecs":{
                  "times":[...],
                  "msecs":[...]
              },
          },
          "US": {
          ...
          },
          ...
      },
      ...
  },
  ...

vhost_traffic_status_filter_check_duplicate

--
Syntaxvhost_traffic_status_filter_check_duplicate <on|off>
Defaulton
Contexthttp, server, location

Description: Enables or disables the deduplication of vhost_traffic_status_filter_by_set_key. It is processed only one of duplicate values(key + name) in each directives(http, server, location) if this option is enabled.

vhost_traffic_status_filter_max_node

--
Syntaxvhost_traffic_status_filter_max_node number [string ...]
Default0
Contexthttp

Description: Enables the limit of filter size using the specified number and string values. If the number is exceeded, the existing nodes are deleted by the LRU algorithm. The number argument is the size of the node that will be limited. The default value 0 does not limit filters. The one node is an object in filterZones in JSON document. The string arguments are the matching string values for the group string value set by vhost_traffic_status_filter_by_set_key directive. Even if only the first part matches, matching is successful like the regular expression /^string.*/. By default, If you do not set string arguments then it applied for all filters.

For examples:

$ vi nginx.conf

http {

    geoip_country /usr/share/GeoIP/GeoIP.dat;

    vhost_traffic_status_zone;

    # The all filters are limited to a total of 16 nodes.
    # vhost_traffic_status_filter_max_node 16

    # The `/^uris.*/` and `/^client::ports.*/` group string patterns are limited to a total of 64 nodes.
    vhost_traffic_status_filter_max_node 16 uris client::ports;

    ...

    server {

        server_name example.org;

        ...

        vhost_traffic_status_filter_by_set_key $uri uris::$server_name;
        vhost_traffic_status_filter_by_set_key $remote_port client::ports::$server_name;
        vhost_traffic_status_filter_by_set_key $geoip_country_code country::$server_name;

    }
}

$ for i in {0..1000}; do curl -H 'Host: example.org' -i "http://localhost:80/test$i"; done

screenshot-vts-filter-max-node

In the above example, the /^uris.*/ and /^client::ports.*/ group string patterns are limited to a total of 16 nodes. The other filters like country::.* are not limited.

vhost_traffic_status_limit

--
Syntaxvhost_traffic_status_limit <on|off>
Defaulton
Contexthttp, server, location

Description: Enables or disables the limit features.

vhost_traffic_status_limit_traffic

--
Syntaxvhost_traffic_status_limit_traffic member:size [code]
Default-
Contexthttp, server, location

Description: Enables the traffic limit for specified member. The member is a member string to limit traffic. The size is a size(k/m/g) to limit traffic. The code is a code to return in response to rejected requests.(Default: 503)

The available member strings are as follows:

vhost_traffic_status_limit_traffic_by_set_key

--
Syntaxvhost_traffic_status_limit_traffic_by_set_key key member:size [code]
Default-
Contexthttp, server, location

Description: Enables the traffic limit for specified key and member. The key is a key string to limit traffic. The member is a member string to limit traffic. The size is a size(k/m/g) to limit traffic. The code is a code to return in response to rejected requests.(Default: 503)

The key syntax is as follows:

The available group strings are as follows:

The available member strings are as follows:

The member is the same as vhost_traffic_status_limit_traffic directive.

vhost_traffic_status_limit_check_duplicate

--
Syntaxvhost_traffic_status_limit_check_duplicate <on|off>
Defaulton
Contexthttp, server, location

Description: Enables or disables the deduplication of vhost_traffic_status_limit_by_set_key. It is processed only one of duplicate values(member | key + member) in each directives(http, server, location) if this option is enabled.

vhost_traffic_status_set_by_filter

--
Syntaxvhost_traffic_status_set_by_filter $variable group/zone/name
Default-
Contexthttp, server, location, if

Description: Get the specified status value stored in shared memory. It can acquire almost all status values and the obtained value is stored in $variable which is first argument.

Caveats: The name is case sensitive. All return values take the integer type.

For examples:

vhost_traffic_status_average_method

--
Syntaxvhost_traffic_status_average_method <AMM|WMA> [period]
DefaultAMM 60s
Contexthttp, server, location

Description: Sets the method which is a formula that calculate the average of response processing times. The period is an effective time of the values used for the average calculation.(Default: 60s) If period set to 0, effective time is ignored. In this case, the last average value is displayed even if there is no requests and after the elapse of time. The corresponding values are requestMsec and responseMsec in JSON.

vhost_traffic_status_histogram_buckets

--
Syntaxvhost_traffic_status_histogram_buckets second ...
Default-
Contexthttp, server, location

Description: Sets the observe buckets to be used in the histograms. By default, if you do not set this directive, it will not work. The second can be expressed in decimal places with a minimum value of 0.001(1ms). The maximum size of the buckets is 32. If this value is insufficient for you, change the NGX_HTTP_VHOST_TRAFFIC_STATUS_DEFAULT_BUCKET_LEN in the src/ngx_http_vhost_traffic_status_node.h

For examples:

Caveats: By default, if you do not set this directive, the histogram statistics does not work. The restored histograms by vhost_traffic_status_dump directive have no affected by changes to the buckets by vhost_traffic_status_histogram_buckets directive. So you must first delete the zone or the dump file before changing the buckets by vhost_traffic_status_histogram_buckets directive. Similar to the above, delete the dump file when using the histogram for the first time.

vhost_traffic_status_bypass_limit

--
Syntaxvhost_traffic_status_bypass_limit <on|off>
Defaultoff
Contexthttp, server, location

Description: Enables or disables to bypass vhost_traffic_status_limit directives. The limit features is bypassed if this option is enabled. This is mostly useful if you want to connect the status web page like /status regardless of vhost_traffic_status_limit directives as follows:

http {
    vhost_traffic_status_zone;

    ...

    server {

        ...

        location /status {
            vhost_traffic_status_bypass_limit on;
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

vhost_traffic_status_bypass_stats

--
Syntaxvhost_traffic_status_bypass_stats <on|off>
Defaultoff
Contexthttp, server, location

Description: Enables or disables to bypass vhost_traffic_status. The traffic status stats features is bypassed if this option is enabled. In other words, it is excluded from the traffic status stats. This is mostly useful if you want to ignore your request in status web page like /status as follows:

http {
    vhost_traffic_status_zone;

    ...

    server {

        ...

        location /status {
            vhost_traffic_status_bypass_stats on;
            vhost_traffic_status_display;
            vhost_traffic_status_display_format html;
        }
    }
}

Releases

To cut a release, create a changelog entry PR with git-chglog

version="v0.2.0"
git checkout -b "cut-${version}"
git-chglog -o CHANGELOG.md --next-tag "${version}"
git add CHANGELOG.md
sed -i "s/NGX_HTTP_VTS_MODULE_VERSION \".*/NGX_HTTP_VTS_MODULE_VERSION \"${version}\"/" src/ngx_http_vhost_traffic_status_module.h
git add src/ngx_http_vhost_traffic_status_module.h
git-chglog -t .chglog/RELNOTES.tmpl --next-tag "${version}" "${version}" | git commit -F-

After the PR is merged, create the new tag and release on the GitHub Releases.

See Also

TODO

Author

YoungJoo.Kim(김영주) [vozltx@gmail.com]