Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default astro preview to localhost instead of 127.0.0.1 to match dev #5747

Closed
matthewp opened this issue Jan 4, 2023 · 1 comment · Fixed by #5753
Closed

Default astro preview to localhost instead of 127.0.0.1 to match dev #5747

matthewp opened this issue Jan 4, 2023 · 1 comment · Fixed by #5753
Assignees
Labels
needs discussion Issue needs to be discussed

Comments

@matthewp
Copy link
Contributor

matthewp commented Jan 4, 2023

No description provided.

@matthewp matthewp added the needs discussion Issue needs to be discussed label Jan 4, 2023
@Chaciej
Copy link

Chaciej commented Mar 19, 2024

After spending a week troubleshooting, I've discovered that Nginx was inconsistently delaying requests made to localhost, while requests to 127.0.0.1 proceeded without issue. Specifically, around 10-20% of my requests to localhost experienced significant delays, arriving after 2 seconds instead of the expected milliseconds. This behavior can be quite misleading and difficult to diagnose. If you're encountering similar issues, consider explicitly using 127.0.0.1 in your configurations to avoid potential inconsistencies with localhost.

server: {
host: '127.0.0.1'
}

Hope this helps someone avoid the confusion I went through!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs discussion Issue needs to be discussed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants