Login resuelto
This commit is contained in:
@@ -4,13 +4,23 @@ import { defineConfig } from 'vite';
|
||||
export default defineConfig({
|
||||
plugins: [sveltekit()],
|
||||
server: {
|
||||
// Puerto: 3001 por defecto en local; Docker lo sobreescribe con PORT=3000
|
||||
// Puerto: dentro del contenedor siempre 3000; Docker mapea 3001:3000 al host
|
||||
port: parseInt(process.env.PORT || '3001'),
|
||||
host: '0.0.0.0',
|
||||
watch: {
|
||||
usePolling: true,
|
||||
interval: 500
|
||||
},
|
||||
// HMR: el browser llega al contenedor a través del puerto 3001 del host
|
||||
hmr: {
|
||||
host: 'localhost',
|
||||
clientPort: parseInt(process.env.HMR_CLIENT_PORT || '3001')
|
||||
},
|
||||
// Permitir que Vite sirva archivos del filesystem del contenedor
|
||||
fs: {
|
||||
allow: ['/app', '.'],
|
||||
strict: false
|
||||
},
|
||||
proxy: {
|
||||
'/api': {
|
||||
target: process.env.PUBLIC_API_URL || 'http://localhost:8000',
|
||||
@@ -23,7 +33,7 @@ export default defineConfig({
|
||||
port: parseInt(process.env.PORT || '3001'),
|
||||
host: '0.0.0.0'
|
||||
},
|
||||
build: {
|
||||
target: 'esnext'
|
||||
}
|
||||
build: {
|
||||
target: 'esnext'
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user