Giter Site home page Giter Site logo

Comments (8)

mislav avatar mislav commented on May 29, 2024 1

I think I've found the problem. The post-receive script sets the GIT_DIR environment variable which affects all subsequent scripts.

Workaround: in your "after_push.sh" deploy script, somewhere near the top, add this:

unset GIT_DIR

Then redeploy. It should make your problem go away.

Of course, you can also edit your "post-receive" git hook on the server to remove the offending export GIT_DIR line. I'll fix the issue in the next version of git-deploy.

from git-deploy.

mislav avatar mislav commented on May 29, 2024

Which version of bundler is installed on your remote machine?

What's inside the "/var/www/apns.amiget.com/app/vendor/bundle/ruby/1.9.1/cache/bundler/git/APNS-cda91886ee68df538b8678105b9abb9553ec394b" directory? Is it owned by the correct user?

from git-deploy.

troex avatar troex commented on May 29, 2024
$ bundle --version
Bundler version 1.0.22

The directory has bare git repo, permissions are all okay, I manage files and deploy under the same user, I also tried chown -R apns:apns but this is not the reason:

$ ls -al vendor/bundle/ruby/1.9.1/cache/bundler/git/APNS-cda91886ee68df538b8678105b9abb9553ec394b/
total 48
drwxr-sr-x  7 apns apns 4096 Mar  7 17:59 .
drwxr-sr-x  5 apns apns 4096 Feb 23 20:45 ..
drwxr-sr-x  2 apns apns 4096 Feb 20 17:26 branches
-rw-r--r--  1 apns apns  123 Feb 20 17:26 config
-rw-r--r--  1 apns apns   73 Feb 20 17:26 description
-rw-r--r--  1 apns apns   89 Mar  9 17:18 FETCH_HEAD
-rw-r--r--  1 apns apns   23 Feb 20 17:26 HEAD
drwxr-sr-x  2 apns apns 4096 Feb 20 17:26 hooks
drwxr-sr-x  2 apns apns 4096 Feb 20 17:26 info
drwxr-sr-x 26 apns apns 4096 Mar  9 17:18 objects
-rw-r--r--  1 apns apns   85 Feb 20 17:26 packed-refs
drwxr-sr-x  4 apns apns 4096 Feb 20 17:26 refs

from git-deploy.

mislav avatar mislav commented on May 29, 2024

Might be an old version of git on your machine, might be a corrupt git repo. Try clearing the cache and try again. It will probably work, but then try reverting to before the Gemfile update and run bundle install again, see if it successfully updates the git repo.

from git-deploy.

troex avatar troex commented on May 29, 2024

Running bundle install manually works fine, that is what I have to each time after failed deploy. I'll try to revert and than make deploy again. Btw git-deploy does not run just bundle install but with some opts, I should try catch and use them. I also would try to update bundler ro 1.1rc. Git is 1.7.2.5 i'm using up-to-date Debian 6.

from git-deploy.

troex avatar troex commented on May 29, 2024

I'll check this out and report back

from git-deploy.

troex avatar troex commented on May 29, 2024

Yeah, it fixes the problem!

from git-deploy.

mislav avatar mislav commented on May 29, 2024

I've pushed a new version of git-deploy with GIT_DIR removed, so future users don't get this problem

from git-deploy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.