導語
今天在使用 Guzzle 的時候,出現了 [curl] 7: Failed to connect to xxx port 80: Connection refused
這個問題。沒有查到相關的中文資料,最終踩了一些坑後解決。簡而言之就是修改 docker-compose.yml
中關於 nginx 的配置,然後重新安裝就可以了。
修改配置
在 NGINX Server
修改如下
networks:
frontend:
aliases:
- you_site
backend:
aliases:
- you_site
重裝 nginx
- 切換到
laradock
中 docker-compose stop nginx
docker-compose build --no-cache nginx
docker-compose up -d nginx
參考資料:GitHub issues。