Closed NigelThorne closed 8 years ago
I just found this... http://stackoverflow.com/questions/7986139/git-error-when-trying-to-push-pre-receive-hook-declined
and it fixed it!
git pull --rebase git push gr master Counting objects: 3, done. Writing objects: 100% (3/3), 208 bytes | 0 bytes/s, done. Total 3 (delta 0), reused 0 (delta 0) To git@192.168.99.100:xxx
- [new branch] master -> master tzm-mac:xxx nwt$
I have no idea why that worked.
I was expecting to see some of the feedback from the receiver script in the output:
echo "Receiving a push.." echo "==> repository: $1" echo "==> revision: $2" echo "==> username: $3" echo "==> fingerprint: $4"
but there was nothing. How do I get this script output to appear in the client?
(there is nothing in docker logs either).
I believe the receiver script was being overwritten by "gitreceive init", so I had to swap the order of a few commands in the docker file. All working as expected now...
Nothing to see here... move along... move along.
I'm trying to put together a simple "gitreceive" docker service, that when pushed a repo will build the docker image and publish it to a docker repository.
I'm just currently trying to get gitreceive to accept a pushed git repo.
https://github.com/NigelThorne/dockerfiles/tree/master/gitreceive-dockerbuilder
I'm getting the following error..
tzm-mac:xxx nwt$ git push gr master Counting objects: 3, done. Writing objects: 100% (3/3), 208 bytes | 0 bytes/s, done. Total 3 (delta 0), reused 0 (delta 0) To ssh://git@192.168.99.100:34567/xxx ! [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to 'ssh://git@192.168.99.100:34567/xxx'
To recreate this...
I build and ran my docker project
push ssh key to server
Then make a repo
ERROR
Thanks for your time and guidance.