Comments (8)
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.
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.
$ 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.
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.
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.
I'll check this out and report back
from git-deploy.
Yeah, it fixes the problem!
from git-deploy.
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)
- $PATH not detected HOT 2
- Alternate checkout path HOT 3
- Use different environments
- differences between git-deploy/git-deploy project HOT 1
- Old net-ssh version in gemspec
- Feature request - custom directory for deploy scripts
- delpoy without commit HOT 1
- More detailed docs?
- Running without an argument will destoy origin/master HOT 4
- git-deploy fails on Windows HOT 2
- Net::SSH::AuthenticationFailed HOT 3
- How to deploy on any remote branch other than master HOT 1
- git deploy download?
- ruby 2.4.1 is not supported HOT 2
- How to migrate database down on rollback? HOT 1
- Can't git deploy setup -r "production" (MacOS Sierra) HOT 2
- multi-servers solution?
- Problems when setting up deployment HOT 1
- Rails 6 support in default deploy scripts HOT 1
- Excluding files on deployment ? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from git-deploy.