Jesús Serrano
Jesús Serrano
NNuxt
Created by Jesús Serrano on 11/4/2024 in #❓・help
BaseUrl configuration problem using proxy
Hi! I am testing with a project in Nuxt 3 with the simple configuration only including the baseUrl inside the app. But it is giving me problems when I duplicate this baseUrl when we use the following proxy to run the web without VPN. When I run the web without JS is entering me fine, if I run the JS I duplicate the baseUrl and I get a 404. Could someone help me, because I can not see why I get that error? --------------- This is the proxy we have --------------- location /apipre/front/mejorac { proxy_pass http://10.239.229.24:3011; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme; add_header Access-Control-Allow-Origin *; add_header Access-Control-Allow-Methods "GET, POST, PUT; DELETE, OPTIONS"; add_header Access-Control-Allow-Headers "Content-Type, Authorization"; chunked_transfer_encoding off; proxy_buffering off; proxy_connect_timeout 300; proxy_send_timeout 300; proxy_read_timeout 300; send_timeout 300; } y con este nuxt.config export default defineNuxtConfig({ compatibilityDate: '2024-04-03', devtools: { enabled: false }, app: { baseURL: '/apipre/front/mejorac', // buildAssetsDir: '/_nuxt/', }, }) Thanks!
34 replies