I created instance on aws running a node application. I installed supervisord to keep the node application up and running. Deployment takes place trough git with a deploment hook.\
The structure is like this:
--- root
|
|--repo |-- hooks
| |-- branches
| |-- etc.
|
|--app
The post-receive hook looks like this.
#!/bin/sh
GIT_WORK_TREE=/home/ubuntu/app
GIT_DIR=/home/ubuntu/repo
export GIT_WORK_TREE
export GIT_DIR
git checkout -f
echo 'Update sub modules.'
git submodule init && git submodule sync && git submodule update
echo 'Install dependencies.'
cd $GIT_WORK_TREE && sudo rm -rf node_modules && sudo npm install
echo 'Restart app'
sudo supervisorctl restart node
Every thing works nice, but sinds i'm start using a submodule in my repo, i'm not able to pull the module and got this message. And got this message:
You need to run this command from the toplevel of the working tree.
My installation is based on http://cuppster.com/2011/05/12/diy-node-js-server-on-amazon-ec2/
My config setting
core.repositoryformatversion=0
core.filemode=true
core.bare=false
core.worktree=/home/ubuntu/app
receive.denycurrentbranch=ignore
How can i fix this issue?
Thanks in advance!!