diff --git a/k8s/ckan.yaml b/k8s/ckan.yaml index 86e39c5..3078ac3 100644 --- a/k8s/ckan.yaml +++ b/k8s/ckan.yaml @@ -24,7 +24,7 @@ spec: labels: {app: ckan} spec: containers: - - image: gcr.io/hasadna-odata/data4dappl-ckan:68f204eb8d4ae18ed7d2c9bcd1d755dd583d5f20 + - image: gcr.io/hasadna-odata/data4dappl-ckan:0850d6038a5b4caec782dfee4117793cd5ea519f name: ckan ports: - {containerPort: 5000} diff --git a/k8s/nginx-conf-d/ckan.inc b/k8s/nginx-conf-d/ckan.inc index 43932c1..3936d5d 100644 --- a/k8s/nginx-conf-d/ckan.inc +++ b/k8s/nginx-conf-d/ckan.inc @@ -1,3 +1,18 @@ +# location /fantastic/ { +# proxy_cache nginx_ckan; +# proxy_pass http://ckan:5000; +# } + +# location /base/images/ { +# proxy_cache nginx_ckan; +# proxy_pass http://ckan:5000; +# } + +# location /odata-logo.png { +# proxy_cache nginx_ckan; +# proxy_pass http://ckan:5000; +# } + location / { client_max_body_size 500m; proxy_pass http://ckan:5000/; diff --git a/k8s/nginx-conf-d/default.conf b/k8s/nginx-conf-d/default.conf index 3cba938..e9faf08 100644 --- a/k8s/nginx-conf-d/default.conf +++ b/k8s/nginx-conf-d/default.conf @@ -1,3 +1,7 @@ +# cache for 1 hour up to 100 MB +proxy_cache_path /tmp/nginx_ckan_cache levels=1:2 keys_zone=nginx_ckan:100m inactive=60m; +proxy_cache_key "$scheme$request_method$host$request_uri"; + server { listen 80; server_name _;