mirror of
https://github.com/gethomepage/homepage.git
synced 2025-12-06 21:57:48 +01:00
Change: prefer IPv4 in docker image (#4954)
This commit is contained in:
@@ -4,7 +4,7 @@ export function middleware(req) {
|
||||
// Check the Host header, if HOMEPAGE_ALLOWED_HOSTS is set
|
||||
const host = req.headers.get("host");
|
||||
const port = process.env.PORT || 3000;
|
||||
let allowedHosts = [`localhost:${port}`];
|
||||
let allowedHosts = [`localhost:${port}`, `127.0.0.1:${port}`];
|
||||
if (process.env.HOMEPAGE_ALLOWED_HOSTS) {
|
||||
allowedHosts = allowedHosts.concat(process.env.HOMEPAGE_ALLOWED_HOSTS.split(","));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user