努力使用 OpenSSL 3 并从 M1 12.3 部署到 Ubuntu 22.04
该应用程序未部署,因为
Net::SSH::Authentication::KeyManagerError: the given identity is known, but the private key could not be loaded:
OpenSSL::PKey::PKeyError (rsa#set_key= is incompatible with OpenSSL 3.0)
安装了 12.3 的 M1 上的本地自制程序仅包含 Openssl1.1 opt/homebrew/Cellar
;因此brew install openssl@3
。我们有一个潜在的香蕉皮,在本地设置了两个版本。
这仍然产生与上面相同的错误。
尝试可以成功。复制密钥 允许通过 ssh 进入服务器。ssh-keygen -t rsa -C "[email protected]" -m PEM
ssh -T [email protected]
ssh-copy-id deploy@server_ip
但现在当通过 M1 部署到 Ubuntu 时cap development deploy
00:00 git:check
01 git ls-remote [email protected]:deploy/app_name.git HEAD
00:00 git:check
01 git ls-remote [email protected]:deploy/app_name.git HEAD
01 [email protected]: Permission denied (publickey).
01 fatal: Could not read from remote repository.
01
01 Please make sure you have the correct access rights
01 and the repository exists.
.rbenv/versions/3.2.1/lib/ruby/gems/3.2.0/gems/sshkit-1.21.4/lib/sshkit/runners/parallel.rb:15:in `rescue in block (2 levels) in execute': Exception while executing as deploy@server_ip: git exit status: 128 (SSHKit::Runner::ExecuteError)
git stdout: Nothing written
git stderr: [email protected]: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
github 拒绝访问存储库。
出于完整性考虑,以下内容似乎可以正确处理
git ls-remote [email protected]:deploy/app_name.git
c317346688eeb92d992a0a98db89719c83a574bd HEAD
c317346688eeb92d992a0a98db89719c83a574bd refs/heads/main
这里有一个主要的灰色区域,非常令人困惑;没有明显的问题候选人。如何才能正确进行此部署?