whyiyhw / chatgpt-wechat

企业微信/微信 安全使用的 ChatGPT 个人助手应用
Apache License 2.0
960 stars 196 forks source link

docker-compose build 报错 #97

Closed isolk closed 11 months ago

isolk commented 1 year ago

[builder 8/11] RUN go mod download: 26.61 go: github.com/gabriel-vasile/mimetype@v1.4.2: Get "https://storage.googleapis.com/proxy-golang-org-prod/457f06b7fc0a8ec6-github.com:gabriel-vasile:mimetype-v1.4.2.zip?Expires=1698979782&GoogleAccessId=gcs-urlsigner-prod%40golang-modproxy.iam.gserviceaccount.com&Signature=EADTZd7l3f1JnZW9JiEmwKOfBGn%2FY07FgVnkhiwG%2B%2BwIzRbYOkgcUS%2F%2FkKNMb4A8C5U0i7pNnVvrTZTw7K7AyJJUYlk8Gqa909aRDSRf63ntIU8K8V%2FYS6rBU3FMUgs0tdGfngpcV1iGrHz8SnBeVDdmrM%2FOQefB%2BKA7VLkb%2FitEgweQWGEBGiK7qCLpAnnBh1FpzjJcwPszjGIlX6RpzO%2BaDR00M8gA6bRgXtQAJEwlsmaYriOZpKEhqMSSDioiMXEa0qVTRSMoFyIgnrcIvKWaw%2BWLFTX1rbdFkDPK3UNvBUyRRYSU0c5VB3HvzzcehqsMhcNF3wIUIpuOxPsSOw%3D%3D": read tcp 172.17.0.2:35956->142.251.42.251:443: read: connection reset by peer 26.61 go: google.golang.org/grpc@v1.58.2: Get "https://storage.googleapis.com/proxy-golang-org-prod/6f1a88ab38813256-google.golang.org:grpc-v1.58.2.zip?Expires=1698976197&GoogleAccessId=gcs-urlsigner-prod%40golang-modproxy.iam.gserviceaccount.com&Signature=J2oakubzgMMSJHU0FmceSSV0zs9w1wqZVviYqYPJL1ZJEtI%2Bm%2F4FBYicMOeZm6vudDm6v3WdQWYDGNnQxOqRes%2FtgLbzgb0iZKrNY%2BTKlE%2B4ajDrDKIEtr6eyy1nq8zTS8ENVz1z6jr1jFlt2BJvHNx7AwWexlrO9ZtcrcaoSIp5YxJJPflh3ZwlXAeqn2a%2BwyLPDprAI%2FLStjKzcWye9pcvyV%2BZeTaYjz6RS1ZYde%2Fldh%2FaHQEglmExpYkyQcW%2Fxq%2Bly7H29uoIU7hH3DMV%2BoIlzBTu33hRWANEFJaGfyKcGxyLfPVBmZlaBCs2XOYNYuGIApslFsvfh9eeCCuwow%3D%3D": read tcp 172.17.0.2:40528->172.217.163.59:443: read: connection reset by peer

机器本身在香港,可以正常访问google.com,请问这种该如何处理。

whyiyhw commented 11 months ago

删除掉 chat/Dockerfile 中的

# 判定 docker 是否能够访问外部网络
RUN ping -c 1 -W 1 google.com > /dev/null \
    && echo "www-ok" \
    || go env -w GOPROXY=https://goproxy.cn,direct

RUN ping -c 1 -W 1 google.com > /dev/null \
    && echo "www-ok" \
    || sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories

再试试