mirror of
https://github.com/withastro/astro.git
synced 2024-12-23 21:53:55 -05:00
Fix port env in standalone mode (#5111)
This commit is contained in:
parent
ef0c543163
commit
df4d84610a
2 changed files with 6 additions and 1 deletions
5
.changeset/short-lemons-fold.md
Normal file
5
.changeset/short-lemons-fold.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
'@astrojs/node': patch
|
||||
---
|
||||
|
||||
fix port in standalone mode
|
|
@ -35,7 +35,7 @@ export function getResolvedHostForHttpServer(host: string | boolean) {
|
|||
}
|
||||
|
||||
export default function startServer(app: NodeApp, options: Options) {
|
||||
const port = process.env.PORT ? Number(process.env.port) : options.port ?? 8080;
|
||||
const port = process.env.PORT ? Number(process.env.PORT) : options.port ?? 8080;
|
||||
const { client } = resolvePaths(options);
|
||||
const handler = middleware(app);
|
||||
|
||||
|
|
Loading…
Reference in a new issue