リモートサーバでsshキーのパスフレーズが設定されていると、Capistranoでのデプロイが失敗します。サーバのsshキーにパスフレーズがあると、Capistranoのデプロイメントに失敗する
しかし、誰パスフレーズが設定されていないとき、それは動作します...
私はまだサーバー上のパスフレーズを使用できるように展開するときにパスワードを入力できるようにしたいと思います。
エラー:
01 mkdir -p /tmp
01 <user>@<ip> 0.183s
Uploading /tmp/git-ssh-<app>-<env>-<me>.sh 100.0%
02 chmod 700 /tmp/git-ssh-<app>-<env>-<me>.sh
02 <user>@<ip> 0.178s
git:check
01 git ls-remote --heads [email protected]:<me>/<my-repo>.git
01 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.
cap aborted!
SSHKit::Runner::ExecuteError: Exception while executing as <user>@<ip>: git exit status: 128
git stdout: Nothing written
git stderr: Permission denied (publickey).
fatal: Could not read from remote repository.
deploy.rb
lock '3.7.1'
set :application, '<app>'
set :repo_url, '[email protected]:<me>/<app>.git'
set :user, '<user>'
set :scm_user, '<me>'
set :deploy_to, '/home/<user>/<app>'
set :scm, :git
set :branch, 'master'
append :linked_files, 'config/database.yml', 'config/secrets.yml'
append :linked_dirs, "log", "tmp/pids", "tmp/cache", "tmp/sockets", "vendor/bundle"
デプロイ/ production.rb
server '<ip>', user: '<user>', roles: %w{app db web}
だから私は希望リー私のサーバがgithubに接続するために使用するために、私はCapistranoが私にパスワードを要求しています。
これは可能ですか?
あなたはCapistranoのサイトの指示に従ってしようとしたことがありますか? http://capistranorb.com/documentation/getting-started/authentication-and-authorisation/ – CryptoPiggy
「SSHエージェントフォワーディング」のセクションをチェックしてください。 – CryptoPiggy