0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

hostsを設定してもChromeで反映されない

Posted at

状況

  • DNSキャッシュの問題ではない
  • *.localhostなどのドメイン名を127.0.0.1以外に割り当てようとしている

原因

cf. https://stackoverflow.com/a/51801611
cf. https://webmasters.stackexchange.com/a/110737

どうもlocalhostを特殊なTLDとして一括ループバックにすれば良かろうという風潮であるらしい。VMに名前でアクセスしたい場合など困るのだが

事情はやや異なるが、予約されたドメイン名の.test.example、またGoogle所有の.app.devも避けた方がいいとのこと。

対処

  • local.mydomain.comなど自分の管理下のサブドメインを用いる
  • 他のブラウザを使う

cf. https://lubtech.geo.jp/2017-09-16/?p=3126
cf. https://support.apple.com/ja-jp/HT207511

.localはいろいろ問題があり、かと言って今後使われる可能性のあるドメインも困るので、自分のドメインを使うのが手っ取り早い。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?