Добавлены уведомления
This commit is contained in:
@@ -4,4 +4,4 @@ add_header Permissions-Policy "camera=(), microphone=(), geolocation=()" always;
|
||||
add_header Cross-Origin-Opener-Policy "same-origin" always;
|
||||
add_header X-Frame-Options "DENY" always;
|
||||
add_header Strict-Transport-Security "max-age=${NGINX_HSTS_MAX_AGE}" always;
|
||||
add_header Content-Security-Policy "default-src 'self'; base-uri 'self'; object-src 'none'; frame-ancestors 'none'; connect-src 'self' https: wss: ${S3_CONNECT_SRC}; img-src 'self' data: blob: https:; script-src 'self'; style-src 'self' 'unsafe-inline'" always;
|
||||
add_header Content-Security-Policy "default-src 'self'; base-uri 'self'; object-src 'none'; frame-src 'none'; frame-ancestors 'none'; connect-src 'self' https: wss: ${S3_CONNECT_SRC}; img-src 'self' data: blob: https:; script-src 'self'; style-src 'self' 'unsafe-inline'" always;
|
||||
|
||||
@@ -86,6 +86,42 @@ server {
|
||||
proxy_cache_valid 200 1h;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location = /api/v1/public/notifications {
|
||||
limit_req zone=notifications_public burst=20 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
proxy_cache off;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location = /api/v1/public/notification-types {
|
||||
limit_req zone=notifications_public burst=20 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
proxy_cache public_cache;
|
||||
proxy_cache_methods GET HEAD;
|
||||
proxy_cache_bypass $http_authorization;
|
||||
proxy_no_cache $http_authorization $upstream_http_set_cookie;
|
||||
proxy_cache_valid 200 1h;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location ~ ^/api/v1/notifications/[0-9a-fA-F-]+/documents/[0-9a-fA-F-]+/download-url$ {
|
||||
limit_req zone=downloads burst=10 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location ~ ^/api/v1/notifications/[0-9a-fA-F-]+/(?:read|hide|cta|buttons/[a-z0-9_-]+)$ {
|
||||
limit_req zone=notifications_action burst=20 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location ~ ^/api/v1/notifications(?:/[0-9a-fA-F-]+|/counter)?$ {
|
||||
limit_req zone=notifications_read burst=30 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location ~ ^/api/v1/uploads(?:/|$) {
|
||||
limit_req zone=notification_upload burst=10 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
proxy_pass http://api_backend;
|
||||
}
|
||||
location ~ ^/api/v1/(?:documents|dialogs)/.+/download-url$ {
|
||||
limit_req zone=downloads burst=10 nodelay;
|
||||
include /etc/nginx/snippets/proxy-common.conf;
|
||||
|
||||
Reference in New Issue
Block a user