簡體   English   中英

Git克隆在ftps上

[英]Git clone over ftps

好的。 所以我的網站托管在InmotionHosting上。 這是一個共享服務器,所以ssh已經出局了。 我一直在通過FTPS訪問它。 我在工作中使用git,所以我很想開始在我的個人網站上使用git。 只是問題,我不確定如何使用git連接到我當前的站點。 我知道它與ftps兼容,因為它在手冊中,但我收到錯誤:

“無法連接到[我的網站]”“無法解析主機”“致命:HTTP請求失敗”“錯誤訪問[我的網站] / info / refs”

我試過了:

git clone [username]:[pass] @ [site] [local repository]

git clone [username] @ [site] [本地存儲庫]

git clone [username] @ [site]:[來自cpanel的端口] [本地存儲庫]

git clone [username]%40 [site] @ [site] [local repository]

什么都行不通。 有什么我想念的嗎? 我需要在服務器上安裝一些東西嗎? 任何幫助表示贊賞。 謝謝!

> man git-clone

結果是:

GIT URLS
       In general, URLs contain information about the transport protocol, the address of the remote server, and the path to the repository.
       Depending on the transport protocol, some of this information may be absent.

       Git natively supports ssh, git, http, https, ftp, ftps, and rsync protocols. The following syntaxes may be used with them:

       ·   ssh://[user@]host.xz[:port]/path/to/repo.git/

       ·   git://host.xz[:port]/path/to/repo.git/

       ·   http[s]://host.xz[:port]/path/to/repo.git/

       ·   ftp[s]://host.xz[:port]/path/to/repo.git/

FTPS似乎是允許的協議之一。

試試git clone ftps://host.xz[:port]/path/to/repo.git/

我想你錯過了一步。 在您“克隆”存儲庫之前,存儲庫本身必須存在(被初始化)。 嘗試克隆服務器上不是git存儲庫的目錄將失敗。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM