Description of problem: create an app and make some change in local repo, then rhc deploy with the commit ID, app can't deploy successfully and show the commit id is invalid. Version-Release number of selected component (if applicable): devenv_3921 rhc-1.16.0 (build from devenv_3921) How reproducible: Always Steps to Reproduce: 1. create an app and disable auto-deploy 2. make any change and git push 3. rhc deploy with commit id Actual results: step2: [root@Daphne n6]# git add .; git commit -amp1; git push [master ee68a39] p1 Committer: root <root@Daphne.(none) 1 files changed, 1 insertions(+), 1 deletions(-) Counting objects: 5, done. Delta compression using up to 8 threads. Compressing objects: 100% (3/3), done. Writing objects: 100% (3/3), 281 bytes, done. Total 3 (delta 2), reused 0 (delta 0) To ssh://52648fb620dcc7e80500007e.rhcloud.com/~/git/n6.git/ 2df151f..ee68a39 master -> master step3: [root@Daphne n6]# rhc deploy ee68a39 -a n6 Deployment of git ref 'ee68a39' in progress for application n6 ... Git ref ee68a39 is invalid Error trying to deploy git ref. You can ssh to your application and try to deploy manually with: gear deploy ee68a39 SSH command finished with exit status = 255 Expected results: app can deploy successfully with commit id. Additional info: 1. the same app can deploy successfully with branch name: rhc deploy master -a n6 2. if ssh into app and run gear deploy ee68a39, still got the message: ref ee68a39 is invalid
The
https://github.com/openshift/origin-server/pull/3943
Commit pushed to master at https://github.com/openshift/origin-server https://github.com/openshift/origin-server/commit/3c562ba1b1973bf54f18084e0b79a05059a1bd02 Bug 1021355 Check for git objects with `git rev-parse` rather than for references with `git show-ref`.
test on devenv_3925, can deploy with commit ID successfully. [root@Daphne perl1]# rhc deploy c89a413 -a perl1 Deployment of git ref 'c89a413' in progress for application perl1 ... Stopping Perl cartridge Waiting for stop to finish Building git ref 'c89a413', commit c89a413 Building Perl cartridge GD is up to date. (2.50) Preparing build for deployment Prepared deployment artifacts in /var/lib/openshift/5265e3558e215305d9000001/app-deployments/2013-10-21_22-38-09.255 Deployment id is 50a2648f Activating deployment Starting Perl cartridge Success move bug to verified.