Git failed to connect to Github

Add SSH to Github, clone github, ping Github, ping Github, clone github, ping Github, ping Github

192.30.253.113 github.com
192.30.252.131 github.com
185.31.16.185 github.global.ssl.fastly.net
74.125.237.1 dl-ssl.google.com
173.194.127.200 groups.google.com
192.30.252.131 github.com
185.31.16.185 github.global.ssl.fastly.net
74.125.128.95 ajax.googleapis.com
Copy the code

Open port

The purchased Ali Cloud lightweight server only has several ports enabled by default, so that the service is released to the server and the access service is in loading state all the time. You can access the service after the port number is configured on the management website of Ali Cloud server

The server does not require confidential login

Reference article: Password-free login to the server

Logging in to the remote server over SSH is tedious and simplifies the two-step process

  • Add local SSH to the ~/.ssh/authorized_keys file on the remote server. This step enables password-free login. You do not need to enter a password when you use SSH to connect to the remote server. The servie SSH restart command is used to restart SSH

  • Create the config file in the local. SSH directory and add the following information

    Host serveName # serveName configurable User root # root configurable HostName X.X.X.X # X.X.X.X indicates the remote server IP address#You can also configure Port to specify a Port
    	
    #After the configuration, you need to use SSH [email protected] to log in to the root user of the X.X.X.X server. In this case, you only need to run SSH serveName to log in
    Copy the code