Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ruby-on-rails/60.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ruby on rails 使用Capistrano 3部署git本地存储库_Ruby On Rails_Git_Deployment_Capistrano_Capistrano3 - Fatal编程技术网

Ruby on rails 使用Capistrano 3部署git本地存储库

Ruby on rails 使用Capistrano 3部署git本地存储库,ruby-on-rails,git,deployment,capistrano,capistrano3,Ruby On Rails,Git,Deployment,Capistrano,Capistrano3,我正在尝试使用capistrano 3部署rails应用程序,但在运行cap production deploy--trace时出现此错误消息: ** Invoke production (first_time) ** Execute production ** Invoke load:defaults (first_time) ** Execute load:defaults ** Invoke deploy (first_time) ** Execute deploy ** Invoke d

我正在尝试使用capistrano 3部署rails应用程序,但在运行
cap production deploy--trace
时出现此错误消息:

** Invoke production (first_time)
** Execute production
** Invoke load:defaults (first_time)
** Execute load:defaults
** Invoke deploy (first_time)
** Execute deploy
** Invoke deploy:starting (first_time)
** Execute deploy:starting
** Invoke deploy:check (first_time)
** Execute deploy:check
** Invoke git:check (first_time)
** Invoke git:wrapper (first_time)
** Execute git:wrapper
 INFO [707e609f] Running /usr/bin/env mkdir -p /tmp/my_app_name/ on 88.xxx.xxx.xxx
DEBUG [707e609f] Command: /usr/bin/env mkdir -p /tmp/my_app_name/
cap aborted!
deploy
/var/lib/gems/1.9.1/gems/net-ssh-2.7.0/lib/net/ssh.rb:215:in `start'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:169:in `ssh'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:122:in `block in _execute'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:119:in `tap'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:119:in `_execute'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:66:in `execute'
/var/lib/gems/1.9.1/gems/capistrano-3.0.1/lib/capistrano/tasks/git.rake:13:in `block (3 levels) in <top (required)>'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:54:in `instance_exec'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:54:in `run'
/var/lib/gems/1.9.1/gems/sshkit-1.2.0/lib/sshkit/runners/parallel.rb:12:in `block (2 levels) in execute'
Tasks: TOP => git:check => git:wrapper
生产。rb

set :application, 'my_app_name'

set :deploy_to, '/var/www/my_app/'
set :deploy_via, :copy
set :scm, :git
set :repo_url, 'file://.git/'
set :stage, :production

role :app, %w{deploy@88.xxx.xxx.xxx}
role :web, %w{deploy@88.xxx.xxx.xxx}

您能否以用户在本地部署的身份运行此命令
mkdir-p/tmp/my\u app\u name/
?我的猜测是,user deploy没有创建该目录所需的权限