Railsアプリをデプロイしようとしています。
$ bundle exec cap production deploy --traceを実行したところ
Directory does not exist '/var/www/html/repo'が発生してデプロイに失敗しました。
[c5ef98e8] Running if test ! -d /var/www/html/repo; then echo "Directory does not exist '/var/www/html/repo'" 1>&2; false; fi as panda@xxx.xxx.xxx.xx DEBUG [c5ef98e8] Command: if test ! -d /var/www/html/repo; then echo "Directory does not exist '/var/www/html/repo'" 1>&2; false; fi DEBUG [7c75396b] Directory does not exist '/var/www/html/repo' cap aborted! SSHKit::Runner::ExecuteError: Exception while executing as panda@xxx.xxx.xxx.xx: if test ! -d /var/www/html/repo; then echo "Directory does not exist '/var/www/html/repo'" 1>&2; false; fi exit status: 1 if test ! -d /var/www/html/repo; then echo "Directory does not exist '/var/www/html/repo'" 1>&2; false; fi stdout: Directory does not exist '/var/www/html/repo' if test ! -d /var/www/html/repo; then echo "Directory does not exist '/var/www/html/repo'" 1>&2; false; fi stderr: Nothing written
なエラー内容になっています。
Directory does not exist '/var/www/html/repo'がでていることから/var/www/html/repoが無いというエラーなのは
わかりますが、何を記述すればいいのでしょうか?
なにも無いディレクトリを作成しておけば、capistrano側で勝手になにか上書きされるのでしょうか?
サイト、参考書などで調べてもなにも出てこないのでどなたか教えて頂けないでしょうか?
宜しくお願いします。
追記3
config/deploy.rb namespace :deploy do desc 'Upload database.yml' task :upload do on roles(:app) do |host| if test "[ ! -d #{shared_path}/config ]" execute "mkdir -p #{shared_path}/config" end upload!('config/database.yml', "#{shared_path}/config/database.yml") end end
としていますがこれが影響しているのでしょうか?
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。