Skip to content

Commit dabeead

Browse files
committed
Fix: Ajustes para correr en Azure App Service
1 parent 64865b0 commit dabeead

4 files changed

Lines changed: 20 additions & 19 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ pnpm install
7878
```bash
7979
pnpm run dev
8080
```
81-
Acceder a la aplicación en `http://localhost:3000`
81+
Acceder a la aplicación en `http://localhost:8080`
8282

8383
### Desplegar en Vercel
8484
```bash

next.config.mjs

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
let userConfig = undefined
1+
let userConfig = undefined;
22
try {
3-
userConfig = await import('./v0-user-next.config')
3+
userConfig = await import("./v0-user-next.config");
44
} catch (e) {
55
// ignore error
66
}
@@ -21,28 +21,29 @@ const nextConfig = {
2121
parallelServerBuildTraces: true,
2222
parallelServerCompiles: true,
2323
},
24-
}
24+
output: "standalone", // 🔥 Agregamos esta línea para Azure App Service
25+
};
2526

26-
mergeConfig(nextConfig, userConfig)
27+
mergeConfig(nextConfig, userConfig);
2728

2829
function mergeConfig(nextConfig, userConfig) {
2930
if (!userConfig) {
30-
return
31+
return;
3132
}
3233

3334
for (const key in userConfig) {
3435
if (
35-
typeof nextConfig[key] === 'object' &&
36+
typeof nextConfig[key] === "object" &&
3637
!Array.isArray(nextConfig[key])
3738
) {
3839
nextConfig[key] = {
3940
...nextConfig[key],
4041
...userConfig[key],
41-
}
42+
};
4243
} else {
43-
nextConfig[key] = userConfig[key]
44+
nextConfig[key] = userConfig[key];
4445
}
4546
}
4647
}
4748

48-
export default nextConfig
49+
export default nextConfig;

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"scripts": {
66
"dev": "next dev",
77
"build": "next build",
8-
"start": "next start",
8+
"start": "PORT=8080 next start",
99
"lint": "next lint"
1010
},
1111
"dependencies": {

pnpm-lock.yaml

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)