开发者

Git error: "fatal: .. does not appear to be a git repository" - when deploying via Capistrano

开发者 https://www.devze.com 2023-01-16 22:32 出处:网络
Background: I\'m aiming to deploy a rails app and am hosting a remote repository for this app on DreamHost. I am using Git for version control. I have created a local repository, committed and pushed

Background: I'm aiming to deploy a rails app and am hosting a remote repository for this app on DreamHost. I am using Git for version control. I have created a local repository, committed and pushed this to the remote repository via ssh. This is roughly the process I took in creating the remote repository. I seem to have created the remote repository successfully. This is what was returned after executing the push to the remote repository:

Brent$ git push --all
$USER@$SERVER.dreamhost.com's password: 
Counting objects: 7, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (4/4), done.
Writing objects: 100% (4/4), 405 bytes, done.
Total 4 (delta 3), reused 0 (delta 0)
To ssh://$USER@$SERVER.dreamhost.com/home/$USER/git/movie-shelf.git
   0e93104..5782611  master -> master

Problem: I'm trying (rather unsuccessfully at the moment) to use Capistrano to handle my deployment process. Executing a cap deploy:check returns:

You appear to have all necessary dependencies instal开发者_C百科led

Yet, when I run cap deploy:cold, I get the following:

Brent$ cap deploy:cold
  * executing `deploy:cold'
  * executing `deploy:update'
 ** transaction: start
  * executing `deploy:update_code'
    updating the cached checkout on all servers
    executing locally: "git ls-remote /home/$USER/git/movie-shelf.git master"
fatal: '/home/$USER/git/movie-shelf.git' does not appear to be a git repository
fatal: The remote end hung up unexpectedly
*** [deploy:update_code] rolling back
  * executing "rm -rf /home/$USER/$APPLICATION/releases/20100919094735; true"
    servers: ["$SERVER.dreamhost.com"]
Password: 
    [$SERVER.dreamhost.com] executing command
    command finished
Command git ls-remote /home/$USER/git/movie-shelf.git master returned status code pid 71920 exit 128

The repository path I have set in my deploy.rb is this:

set :repository, "/home/#{user}/git/movie-shelf.git"

Whew. So, after all that, I'm basically wondering what I'm missing that could be causing that error. :)

0

精彩评论

暂无评论...
验证码 换一张
取 消