root@vmi465483:~# cat /etc/nginx/sites-enabled/dspace.conf server { server_name repositorio.unijuanpablo.edu.pe; root /var/www/html/; client_max_body_size 2000m; location / { return 301 http://repositorio.unijuanpablo.edu.pe/xmlui/; } location ^~ /.well-known/acme-challenge/ { root /var/www/html; } location /jspui/ { index index.jsp; proxy_set_header X-Forwarded-Host $host; proxy_set_header X-Forwarded-Server $host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_pass http://localhost:8080/jspui/; proxy_redirect http://localhost:8080/jspui/ https://repositorio.unijuanpablo.edu.pe/jspui/; proxy_buffering off; proxy_store off; proxy_connect_timeout 120; proxy_send_timeout 120; proxy_read_timeout 120; } location /oai/ { proxy_set_header X-Forwarded-Host $host; proxy_set_header X-Forwarded-Server $host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_pass http://localhost:8080/oai/; proxy_redirect http://localhost:8080/oai/ https://repositorio.unijuanpablo.edu.pe/oai/; proxy_buffering off; proxy_store off; proxy_connect_timeout 120; proxy_send_timeout 120; proxy_read_timeout 120; } location /xmlui/ { proxy_set_header X-Forwarded-Host $host; proxy_set_header X-Forwarded-Server $host; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_pass http://localhost:8080/xmlui/; proxy_redirect http://localhost:8080/xmlui https://repositorio.unijuanpablo.edu.pe/xmlui; proxy_buffering off; proxy_store off; proxy_connect_timeout 120; proxy_send_timeout 120; proxy_read_timeout 120; } listen 443 ssl; # managed by Certbot ssl_certificate /etc/letsencrypt/live/repositorio.unijuanpablo.edu.pe/fullchain.pem; # managed by Certbot ssl_certificate_key /etc/letsencrypt/live/repositorio.unijuanpablo.edu.pe/privkey.pem; # managed by Certbot include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot } server { if ($host = repositorio.unijuanpablo.edu.pe) { return 301 https://$host$request_uri; } # managed by Certbot listen 80; server_name repositorio.unijuanpablo.edu.pe; return 404; # managed by Certbot } root@vmi465483:~#