-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfigmap.yaml
52 lines (45 loc) · 1.45 KB
/
configmap.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
apiVersion: v1
kind: ConfigMap
metadata:
name: azure-blob-proxy-nginx-config
namespace: default
data:
default.conf: |
proxy_cache_path /var/cache/nginx/proxy
levels=1:2
keys_zone=azure_blob_proxy_cache:10m
max_size=10g
inactive=1h
use_temp_path=off;
server {
listen 80;
server_name localhost;
server_tokens off;
location / {
# Proxy caching configuration. Customize this for your needs.
proxy_cache azure_blob_proxy_cache;
proxy_cache_valid 200 302 1h;
proxy_cache_valid 404 1m;
proxy_cache_valid 403 30s;
proxy_cache_methods GET;
proxy_cache_revalidate on;
proxy_cache_background_update on;
proxy_cache_lock on;
proxy_cache_use_stale error timeout http_500 http_502 http_503 http_504;
proxy_cache_key "$request_method$host$uri";
proxy_pass http://127.0.0.1:8080;
# Use keep alive connections in order to improve performance
proxy_http_version 1.1;
proxy_set_header Connection '';
proxy_pass_request_headers off;
proxy_intercept_errors on;
}
location /healthz {
proxy_pass http://127.0.0.1:8080;
access_log off;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}