Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
nginx
GitHub Repository: nginx/nginx.org
Path: blob/main/xml/en/docs/ngx_mgmt_module.xml
1 views
1
<?xml version="1.0"?>
2
3
<!--
4
Copyright (C) Nginx, Inc.
5
-->
6
7
<!DOCTYPE module SYSTEM "../../../dtd/module.dtd">
8
9
<module name="Module ngx_mgmt_module"
10
link="/en/docs/ngx_mgmt_module.html"
11
lang="en"
12
rev="2">
13
14
<section id="summary">
15
16
<para>
17
The <literal>ngx_mgmt_module</literal> module enables
18
NGINX Plus license verification and usage reporting.
19
This is mandatory for each NGINX Plus instance since 1.27.2 (
20
<link url="https://docs.nginx.com/nginx/releases/#r33">NGINX Plus R33</link>).
21
</para>
22
23
<para>
24
A JWT license file named <literal>license.jwt</literal>
25
should be located at
26
<literal>/etc/nginx/</literal> for Linux or
27
<literal>/usr/local/etc/nginx/</literal> for FreeBSD
28
or at the path specified by the <link id="license_token"/> directive.
29
The license file is available from
30
<link url="https://my.f5.com">MyF5</link>.
31
</para>
32
33
<para>
34
Usage report is sent directly or via <link id="proxy">proxy</link>
35
to F5 licensing endpoint
36
<link id="usage_report">every hour</link> using the
37
<link id="ssl_verify">secure</link> connection.
38
Optionally, in network-restricted environments
39
reporting can be <link id="usage_report">configured</link> to
40
<link url="https://docs.nginx.com/nginx-management-suite/about/">F5 NGINX
41
Instance Manager</link> from which the report can be sent
42
to F5 licensing endpoint.
43
</para>
44
45
<para>
46
By default, if the <link id="enforce_initial_report">initial usage report</link>
47
is not received by F5 licensing endpoint, nginx will stop processing traffic.
48
</para>
49
50
<para>
51
Automatic license renewal is supported since 1.29.0
52
(<link url="https://docs.nginx.com/nginx/releases/#r35">NGINX Plus R35</link>)
53
for instances that report directly to the F5 licensing endpoint.
54
On renewal, NGINX downloads the updated JWT from F5 licensing endpoint
55
and applies it without
56
configuration <link doc="switches.xml">reload</link>.
57
The updated license is stored
58
in the <link id="state_path">state_path</link> directory.
59
</para>
60
61
<para>
62
<note>
63
This module is available as part of our
64
<commercial_version>commercial subscription</commercial_version>.
65
</note>
66
</para>
67
68
</section>
69
70
71
<section id="example" name="Example Configuration">
72
73
<para>
74
<example>
75
mgmt {
76
# in case if custom path is required
77
license_token custom/file/path/license.jwt;
78
79
# in case of reporting to NGINX Instance Manager
80
usage_report endpoint=NIM_FQDN;
81
}
82
</example>
83
</para>
84
85
</section>
86
87
88
<section id="directives" name="Directives">
89
90
<directive name="mgmt">
91
<syntax block="yes"/>
92
<default/>
93
<context>main</context>
94
95
<para>
96
Provides the configuration file context in which
97
usage reporting and license management directives
98
are specified.
99
</para>
100
101
</directive>
102
103
104
<directive name="enforce_initial_report">
105
<syntax><literal>on</literal> | <literal>off</literal></syntax>
106
<default>on</default>
107
<context>mgmt</context>
108
<appeared-in>1.27.2</appeared-in>
109
110
<para>
111
Enables or disables the 180-day grace period
112
for sending the initial usage report.
113
</para>
114
115
<para>
116
The initial usage report is sent immediately
117
upon nginx first start after installation.
118
By default, if the initial report is not received by F5 licensing endpoint,
119
nginx stops processing traffic until the report is successfully delivered.
120
Setting the directive value to <literal>off</literal> enables
121
the 180-day grace period during which
122
the initial usage report must be received by F5 licensing endpoint.
123
</para>
124
125
</directive>
126
127
128
<directive name="license_token">
129
<syntax><value>file</value></syntax>
130
<default>license.jwt</default>
131
<context>mgmt</context>
132
<appeared-in>1.27.2</appeared-in>
133
134
<para>
135
Specifies a JWT license <value>file</value>.
136
By default, the <value>license.jwt</value> file is expected to be at
137
<literal>/etc/nginx/</literal> for Linux or at
138
<literal>/usr/local/etc/nginx/</literal> for FreeBSD.
139
</para>
140
141
</directive>
142
143
144
<directive name="proxy">
145
<syntax><value>host</value>:<value>port</value></syntax>
146
<default/>
147
<context>mgmt</context>
148
<appeared-in>1.27.4</appeared-in>
149
150
<para>
151
Sets the HTTP CONNECT proxy
152
used for sending the usage report.
153
</para>
154
155
</directive>
156
157
158
<directive name="proxy_username">
159
<syntax><value>string</value></syntax>
160
<default/>
161
<context>mgmt</context>
162
<appeared-in>1.27.4</appeared-in>
163
164
<para>
165
Sets the user name used for authentication on
166
the <link id="proxy">proxy</link>.
167
</para>
168
169
</directive>
170
171
172
<directive name="proxy_password">
173
<syntax><value>string</value></syntax>
174
<default/>
175
<context>mgmt</context>
176
<appeared-in>1.27.4</appeared-in>
177
178
<para>
179
Sets the password used for authentication on
180
the <link id="proxy">proxy</link>.
181
</para>
182
183
<para>
184
The password is sent unencrypted by default.
185
If the proxy supports TLS, the connection to the proxy can be
186
protected with the <link doc="stream/ngx_stream_proxy_module.xml">stream</link>
187
module:
188
<example>
189
mgmt {
190
proxy 127.0.0.1:8080;
191
proxy_username &lt;name&gt;;
192
proxy_password &lt;password&gt;;
193
}
194
195
stream {
196
server {
197
listen 127.0.0.1:8080;
198
199
proxy_ssl on;
200
proxy_ssl_verify on;
201
proxy_ssl_trusted_certificate &lt;proxy_ca_file&gt;;
202
203
proxy_pass &lt;proxy_host&gt;:&lt;proxy_port&gt;;
204
}
205
}
206
</example>
207
</para>
208
209
</directive>
210
211
212
<directive name="resolver">
213
<syntax>
214
<value>address</value> ...
215
[<literal>valid</literal>=<value>time</value>]
216
[<literal>ipv4</literal>=<literal>on</literal>|<literal>off</literal>]
217
[<literal>ipv6</literal>=<literal>on</literal>|<literal>off</literal>]
218
[<literal>status_zone</literal>=<value>zone</value>]</syntax>
219
<default/>
220
<context>mgmt</context>
221
222
<para>
223
Configures name servers used to resolve usage reporting endpoint name.
224
By default, the system resolver is used.
225
</para>
226
227
<para>
228
See <link doc="http/ngx_http_core_module.xml" id="resolver"/> for details.
229
</para>
230
231
</directive>
232
233
234
<directive name="ssl_crl">
235
<syntax><value>file</value></syntax>
236
<default/>
237
<context>mgmt</context>
238
239
<para>
240
Specifies a <value>file</value> with revoked certificates (CRL)
241
in the PEM format used to <link id="ssl_verify">verify</link>
242
the certificate of the usage reporting endpoint.
243
When using intermediate certificates, their CRLs should be
244
specified in the same file.
245
</para>
246
247
</directive>
248
249
250
<directive name="ssl_trusted_certificate">
251
<syntax><value>file</value></syntax>
252
<default>system CA bundle</default>
253
<context>mgmt</context>
254
255
<para>
256
Specifies a <value>file</value> with trusted CA certificates in the PEM format
257
used to <link id="ssl_verify">verify</link>
258
the certificate of the usage reporting endpoint.
259
</para>
260
261
</directive>
262
263
264
<directive name="ssl_verify">
265
<syntax><literal>on</literal> | <literal>off</literal></syntax>
266
<default>on</default>
267
<context>mgmt</context>
268
269
<para>
270
Enables or disables verification of the usage reporting endpoint certificate.
271
</para>
272
273
<para>
274
<note>
275
Before 1.27.2, the default value was <literal>off</literal>.
276
</note>
277
</para>
278
279
</directive>
280
281
282
<directive name="state_path">
283
<syntax><value>path</value></syntax>
284
<default/>
285
<context>mgmt</context>
286
<appeared-in>1.27.2</appeared-in>
287
288
<para>
289
Defines a directory for storing state files
290
(<literal>nginx-mgmt-*</literal>)
291
created by the <literal>ngx_mgmt_module</literal> module.
292
The default directory
293
for Linux is <literal>/var/lib/nginx/state</literal>,
294
for FreeBSD is <literal>/var/db/nginx/state</literal>.
295
</para>
296
297
</directive>
298
299
300
<directive name="usage_report">
301
<syntax> [<literal>endpoint</literal>=<value>address</value>]
302
[<literal>interval</literal>=<value>time</value>]</syntax>
303
<default>endpoint=product.connect.nginx.com interval=1h</default>
304
<context>mgmt</context>
305
306
<para>
307
Sets the <value>address</value> and <value>port</value>
308
of the usage reporting endpoint.
309
The <literal>interval</literal> parameter sets an interval between
310
two consecutive reports.
311
<note>
312
Before 1.27.2, the default values were
313
<literal>nginx-mgmt.local</literal> and
314
<literal>30m</literal>.
315
</note>
316
</para>
317
318
</directive>
319
320
</section>
321
322
</module>
323
324