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

Failed to download csghub artifact. #10

Closed
samchen8008 opened this issue Jan 14, 2024 · 6 comments
Closed

Failed to download csghub artifact. #10

samchen8008 opened this issue Jan 14, 2024 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@samchen8008
Copy link

(base) samchen@bogon ~ % export SERVER_DOMAIN=172.20.7.104
(base) samchen@bogon ~ % curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml -o all-in-one-CN.yml
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- 0:00:46 --:--:-- 0

0 0 0 0 0 0 0 0 --:--:-- 0:01:15 --:--:-- 0
curl: (28) Failed to connect to raw.githubusercontent.com port 443 after 75015 ms: Couldn't connect to server
(base) samchen@bogon ~ %
(base) samchen@bogon ~ %
(base) samchen@bogon ~ % ping raw.githubusercontent.com
PING raw.githubusercontent.com (182.43.124.6): 56 data bytes
64 bytes from 182.43.124.6: icmp_seq=0 ttl=53 time=45.702 ms
64 bytes from 182.43.124.6: icmp_seq=1 ttl=53 time=41.738 ms
64 bytes from 182.43.124.6: icmp_seq=2 ttl=53 time=42.661 ms
64 bytes from 182.43.124.6: icmp_seq=3 ttl=53 time=42.102 ms
64 bytes from 182.43.124.6: icmp_seq=4 ttl=53 time=42.455 ms
64 bytes from 182.43.124.6: icmp_seq=5 ttl=53 time=36.326 ms
64 bytes from 182.43.124.6: icmp_seq=6 ttl=53 time=35.578 ms
64 bytes from 182.43.124.6: icmp_seq=7 ttl=53 time=44.073 ms
^C
--- raw.githubusercontent.com ping statistics ---
8 packets transmitted, 8 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 35.578/41.329/45.702/3.327 ms

@samchen8008 samchen8008 added the bug Something isn't working label Jan 14, 2024
@samchen8008
Copy link
Author

I just followed the below steps:
快速使用
可使用如下命令快速部署一个CSBHub实例到指定环境。

export SERVER_DOMAIN=[IP Address]
curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one.yml -o all-in-one.yml
docker compose -f all-in-one.yml up -d
国内用户可选择使用阿里容器镜像服务的部署脚本,加快服务启动,命令如下:

export SERVER_DOMAIN=[IP Address]
curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml -o all-in-one-CN.yml
docker compose -f all-in-one-CN.yml up -d
部署完毕后,就可以在浏览器上通过http://[IP Address]访问到新部署的CSGHub实例。(初始化管理员账号:admin001/admin001)

详细使用方法可参看使用文档

注意:

SERVER_DOMAIN 为目标主机的IP地址或者域名,请不要使用127.0.0.1或者localhost
当前仅仅支持x86_64架构系统。
使用该all-in-one脚本启动过的实例无法有效持久化用户数据。服务启动后,使用docker compose up命令重新加载服务会出现错误,此时可以选择使用docker compose down -v命令彻底清除实例再重新启动,或者使用完整版一键部署脚本进行服务部署。

@wayneliu0019
Copy link
Collaborator

国内从github上拉去文件,这种情况会偶尔发生,有的是因为raw.githubusercontent.com这个域名被污染,通过显式在/etc/hosts指定这个域名的地址来解决。可以尝试使用如下两种方法:

指定IP

https://site.ip138.com/ 查询出raw.githubusercontent.com的IP地址,然后配置在主机的/etc/hosts

设置dns地址

为主机设置8.8.8.8作为dns地址

我测试了5、6个不同的虚拟机,出现了同样的情况,解决方法是:在主机的/etc/resolv.conf中增加 nameserver 8.8.8.8,再此curl就可以了,如下:

直接curl失败:

root@m3:~# curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml -o all-in-one-CN.yml
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:27 --:--:--     0^C
root@m3:~#
root@m3:~#
root@m3:~# wget  https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml
--2024-01-14 13:39:42--  https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 182.43.124.6
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|182.43.124.6|:443... ^C

增加nameserver 8.8.8.8 dns解析:

root@m3:~# cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "systemd-resolve --status" to see details about the actual nameservers.

nameserver 8.8.8.8
nameserver 127.0.0.53
options timeout:2 attempts:3 rotate single-request-reopen

再次执行curl命令成功:

root@m3:~# curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml -o all-in-one-CN.yml
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5585  100  5585    0     0   2651      0  0:00:02  0:00:02 --:--:--  2651

@samchen8008

@KinglyWayne
Copy link
Member

国内从github上拉去文件,这种情况会偶尔发生,有的是因为raw.githubusercontent.com这个域名被污染,通过显式在/etc/hosts指定这个域名的地址来解决。可以尝试使用如下两种方法:

指定IP

https://site.ip138.com/ 查询出raw.githubusercontent.com的IP地址,然后配置在主机的/etc/hosts

设置dns地址

为主机设置8.8.8.8作为dns地址

我测试了5、6个不同的虚拟机,出现了同样的情况,解决方法是:在主机的/etc/resolv.conf中增加 nameserver 8.8.8.8,再此curl就可以了,如下:

直接curl失败:

root@m3:~# curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml -o all-in-one-CN.yml
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:27 --:--:--     0^C
root@m3:~#
root@m3:~#
root@m3:~# wget  https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml
--2024-01-14 13:39:42--  https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 182.43.124.6
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|182.43.124.6|:443... ^C

增加nameserver 8.8.8.8 dns解析:

root@m3:~# cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "systemd-resolve --status" to see details about the actual nameservers.

nameserver 8.8.8.8
nameserver 127.0.0.53
options timeout:2 attempts:3 rotate single-request-reopen

再次执行curl命令成功:

root@m3:~# curl -L https://raw.githubusercontent.com/OpenCSGs/csghub/main/all-in-one-CN.yml -o all-in-one-CN.yml
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  5585  100  5585    0     0   2651      0  0:00:02  0:00:02 --:--:--  2651

@samchen8008

how about add a alternative file address (such as aliyun s3 public file url) for Chinese user?

@samchen8008
Copy link
Author

Better to have some mirrors in China

@wayneliu0019
Copy link
Collaborator

wayneliu0019 commented Jan 14, 2024

Aliyun OSS has been added as a yml file source , please refer here:https://github.com/OpenCSGs/csghub?tab=readme-ov-file#%E5%BF%AB%E9%80%9F%E4%BD%BF%E7%94%A8

@KinglyWayne
Copy link
Member

Docker image mirror and docker-compose file mirror have been added for Chinese users and checked.
Issue closed for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants