我想在其他设备上通过域名而不是IP地址访问我的Mac本地web服务器。
例如,使用“custom.domain:8080”而不是“192.168.xx.xx:8080”。
最简单的方法是什么?
谢谢。
/etc/hosts
192.168.xx.xx custom.domain
然后访问http://custom.domain:8080
192.168.0.105 mydomain.com