diff --git a/Dockerfile b/Dockerfile index fd8fc98..6b2f239 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,3 +4,4 @@ COPY privkey.pem /etc/nginx/ COPY fullchain.pem /etc/nginx/ COPY default.conf /etc/nginx/conf.d/ COPY index.html /usr/share/nginx/html/404/ +COPY robots.txt /usr/share/nginx/html/robots.txt diff --git a/default.conf b/default.conf index a6a12ba..0145a56 100644 --- a/default.conf +++ b/default.conf @@ -1,6 +1,46 @@ server { root /usr/share/nginx/html; + index index.html index.htm index.nginx-debian.html; + server_name hbpn.link; # managed by Certbot + client_max_body_size 70M; + + location /404 { + try_files $uri $uri/ /index.html; + } + + location /answer/ { + add_header Access-Control-Allow-Origin hbpn.link always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type,x-sessionkey always; + add_header Access-Control-Expose-Headers x-sessionkey always; + add_header Access-Control-Allow-Methods OPTIONS,GET,POST,PATCH,PUT,DELETE; + proxy_pass http://10.8.0.9:1490/; + } + + location /squizimages { + add_header Access-Control-Allow-Origin hbpn.link always; + add_header Access-Control-Allow-Credentials true always; + add_header Access-Control-Allow-Headers content-type always; + add_header Access-Control-Allow-Methods GET; + chunked_transfer_encoding off; + proxy_buffering off; + proxy_cache off; + proxy_pass https://storage.yandexcloud.net; + } + + location / { + proxy_pass http://respondent; + } + + listen 443 ssl; # managed by Certbot + ssl_certificate /etc/nginx/certs/live/pena.digital/fullchain.pem; # managed by Certbot + ssl_certificate_key /etc/nginx/certs/live/pena.digital/privkey.pem; # managed by Certbot + +} +server { + root /usr/share/nginx/html; + index index.html index.htm index.nginx-debian.html; server_name quiz.pena.digital; # managed by Certbot client_max_body_size 70M; diff --git a/robots.txt b/robots.txt new file mode 100644 index 0000000..ba699d0 --- /dev/null +++ b/robots.txt @@ -0,0 +1,9 @@ +User-agent: * +Allow: / +Allow: /landings +Allow: /mobileapps +Allow: /corporatesites +Allow: /devops +Allow: /cloudnative +Allow: /design +Allow: /crmsystems