Skip to content

Commit c5738f2

Browse files
SIMPLE FIX: Use exact allowedHosts configuration
1 parent 80d24ed commit c5738f2

File tree

2 files changed

+5
-27
lines changed

2 files changed

+5
-27
lines changed

astro.config.mjs

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,10 @@ export default defineConfig({
1414
site,
1515
vite: {
1616
server: {
17-
host: '0.0.0.0',
18-
port: 4321,
17+
allowedHosts: ['gdg-docs-426637717447.us-central1.run.app'],
1918
},
2019
preview: {
21-
host: '0.0.0.0',
22-
port: 8080,
23-
strictPort: false,
24-
allowedHosts: [
25-
'gdg-docs-426637717447.us-central1.run.app',
26-
'localhost',
27-
'127.0.0.1',
28-
'0.0.0.0',
29-
'.run.app'
30-
]
20+
allowedHosts: ['gdg-docs-426637717447.us-central1.run.app'],
3121
}
3222
},
3323
integrations: [

vite.config.js

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,9 @@ import { defineConfig } from 'vite';
22

33
export default defineConfig({
44
server: {
5-
host: '0.0.0.0',
6-
port: 4321,
5+
allowedHosts: ['gdg-docs-426637717447.us-central1.run.app'],
76
},
87
preview: {
9-
host: '0.0.0.0',
10-
port: 8080,
11-
strictPort: false,
12-
// Add the exact Cloud Run host
13-
allowedHosts: [
14-
'gdg-docs-426637717447.us-central1.run.app',
15-
'localhost',
16-
'127.0.0.1',
17-
'0.0.0.0',
18-
'.run.app',
19-
'.app'
20-
]
21-
}
8+
allowedHosts: ['gdg-docs-426637717447.us-central1.run.app'],
9+
},
2210
});

0 commit comments

Comments
 (0)