server {
    listen   80;
    server_name nginx-ascle-service;
    client_max_body_size 2m;

    access_log /data/log/ascle/nginx/nginx-access.log;
    error_log /data/log/ascle/nginx/nginx-error.log;
    root /srv/apps/ascle-frontend/dist/;

    location /api {
        proxy_set_header X-Forwarded-Host $server_name;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $http_remoteip;
        proxy_set_header Host $http_host;
        proxy_pass http://ascle-service;
    }

    location / {
        try_files $uri $uri/ /index.html;
    }
    location  /account/login {
        return 301 /;
    }
}
