capistrano3.4.0 배치는 자동으로 로그인할 수 없습니다

2609 단어
배치할 때 서버 비밀번호를 입력해야 해서 직접 로그인할 수 없음
DEBUG [ab5be9b4] Running /usr/bin/env [ -d $HOME/.rbenv/versions/2.3.0 ] on 10.103.xx.xx
DEBUG [05871a47] Running /usr/bin/env [ -d $HOME/.rbenv/versions/2.3.0 ] on 10.103.xx.xx
DEBUG [dd74890c] Running /usr/bin/env [ -d $HOME/.rbenv/versions/2.3.0 ] on 10.103.xx.xx
DEBUG [ab5be9b4] Command: [ -d $HOME/.rbenv/versions/2.3.0 ]
DEBUG [05871a47] Command: [ -d $HOME/.rbenv/versions/2.3.0 ]
DEBUG [dd74890c] Command: [ -d $HOME/.rbenv/versions/2.3.0 ]
Text will be echoed in the clear. Please install the HighLine or Termios libraries to suppress echoed text.
root@10.103.xx.xx's password:Text will be echoed in the clear. Please install the HighLine or Termios libraries 
to suppress echoed text.
[email protected]'s password:Text will be echoed in the clear. Please install the HighLine or Termios libraries
 to suppress echoed text.
[email protected]'s password:

3.0+ 버전 config/deploy.rb 사용자 쓰기 취소
set :user, 'webuser'

이런 식으로 써야 돼요.
set :ssh_options, { user: 'webuser' }

https://github.com/capistrano/capistrano/blob/621985511529893d972e79452ad63eb54430fb4c/lib/capistrano/templates/stage.rb.erb
또는 배포/생산 중입니다.rb에서 ssh 사용자 이름 설정
# server 'example.com', user: 'deploy', roles: %w{app db web}, my_property: :my_value
# server 'example.com', user: 'deploy', roles: %w{app web}, other_property: :other_value
# server 'db.example.com', user: 'deploy', roles: %w{db}

좋은 웹페이지 즐겨찾기