Separate third party NGINX configuration (#10470)
* Document container separation * Separate configurations
This commit is contained in:
parent
d6a0f46c32
commit
9ed0d7f7af
19 changed files with 158 additions and 36 deletions
|
|
@ -175,7 +175,7 @@ http {
|
|||
|
||||
{{ range $index, $file := $all.MaxmindEditionFiles }}
|
||||
{{ if eq $file "GeoLite2-Country.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoLite2-Country.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoLite2-Country.mmdb {
|
||||
$geoip2_country_code source=$remote_addr country iso_code;
|
||||
$geoip2_country_name source=$remote_addr country names en;
|
||||
$geoip2_country_geoname_id source=$remote_addr country geoname_id;
|
||||
|
|
@ -186,7 +186,7 @@ http {
|
|||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoIP2-Country.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoIP2-Country.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoIP2-Country.mmdb {
|
||||
$geoip2_country_code source=$remote_addr country iso_code;
|
||||
$geoip2_country_name source=$remote_addr country names en;
|
||||
$geoip2_country_geoname_id source=$remote_addr country geoname_id;
|
||||
|
|
@ -197,7 +197,7 @@ http {
|
|||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoLite2-City.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoLite2-City.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoLite2-City.mmdb {
|
||||
$geoip2_city_country_code source=$remote_addr country iso_code;
|
||||
$geoip2_city_country_name source=$remote_addr country names en;
|
||||
$geoip2_city_country_geoname_id source=$remote_addr country geoname_id;
|
||||
|
|
@ -220,7 +220,7 @@ http {
|
|||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoIP2-City.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoIP2-City.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoIP2-City.mmdb {
|
||||
$geoip2_city_country_code source=$remote_addr country iso_code;
|
||||
$geoip2_city_country_name source=$remote_addr country names en;
|
||||
$geoip2_city_country_geoname_id source=$remote_addr country geoname_id;
|
||||
|
|
@ -243,21 +243,21 @@ http {
|
|||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoLite2-ASN.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoLite2-ASN.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoLite2-ASN.mmdb {
|
||||
$geoip2_asn source=$remote_addr autonomous_system_number;
|
||||
$geoip2_org source=$remote_addr autonomous_system_organization;
|
||||
}
|
||||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoIP2-ASN.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoIP2-ASN.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoIP2-ASN.mmdb {
|
||||
$geoip2_asn source=$remote_addr autonomous_system_number;
|
||||
$geoip2_org source=$remote_addr autonomous_system_organization;
|
||||
}
|
||||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoIP2-ISP.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoIP2-ISP.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoIP2-ISP.mmdb {
|
||||
$geoip2_isp source=$remote_addr isp;
|
||||
$geoip2_isp_org source=$remote_addr organization;
|
||||
$geoip2_asn source=$remote_addr default=0 autonomous_system_number;
|
||||
|
|
@ -265,13 +265,13 @@ http {
|
|||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoIP2-Connection-Type.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoIP2-Connection-Type.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoIP2-Connection-Type.mmdb {
|
||||
$geoip2_connection_type connection_type;
|
||||
}
|
||||
{{ end }}
|
||||
|
||||
{{ if eq $file "GeoIP2-Anonymous-IP.mmdb" }}
|
||||
geoip2 /etc/nginx/geoip/GeoIP2-Anonymous-IP.mmdb {
|
||||
geoip2 /etc/ingress-controller/geoip/GeoIP2-Anonymous-IP.mmdb {
|
||||
$geoip2_is_anon source=$remote_addr is_anonymous;
|
||||
$geoip2_is_anonymous source=$remote_addr default=0 is_anonymous;
|
||||
$geoip2_is_anonymous_vpn source=$remote_addr default=0 is_anonymous_vpn;
|
||||
|
|
@ -469,7 +469,7 @@ http {
|
|||
ssl_session_tickets {{ if $cfg.SSLSessionTickets }}on{{ else }}off{{ end }};
|
||||
|
||||
{{ if not (empty $cfg.SSLSessionTicketKey ) }}
|
||||
ssl_session_ticket_key /etc/nginx/tickets.key;
|
||||
ssl_session_ticket_key /etc/ingress-controller/tickets.key;
|
||||
{{ end }}
|
||||
|
||||
# slightly reduce the time-to-first-byte
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue