Bug 1017154 - [deploy]App is still deployed on master when a non master deployment_branch is configured
Summary: [deploy]App is still deployed on master when a non master deployment_branch i...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Andy Goldstein
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-10-09 10:52 UTC by Jianwei Hou
Modified: 2015-05-14 23:29 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-17 13:34:33 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Jianwei Hou 2013-10-09 10:52:18 UTC
Description of problem:
Given deployment_branch is configured to the app, and a new branch is created, when I push the code, there are some errors shown up and the branch is not deployed to the app

Version-Release number of selected component (if applicable):
On devenv_3874

How reproducible:
Always

Steps to Reproduce:
1. Create a diy application
rhc create-app d1 diy-0.1
2. Create a new branch, add current branch name in index.html
git checkout -b br1
edit content under "h1" tag in index.html, eg: <h1>Branch br1</h1>
git commit diy/index.html -m 'branch br1 updates'
3. Invoke rest api to make the application auto deploy the br1 branch
curl -s -k -H 'Content-Type: Application/json' --user jhou:x https://ec2-184-72-155-218.compute-1.amazonaws.com/broker/rest/domain/jhou/application/d1 -X PUT -d '{"deployment_branch":"br1"}'
4. Push the changes
git push -u origin br1

Actual results:
After step 4:
Total 4 (delta 1), reused 0 (delta 0)
remote: fatal: Not a valid object name br1
remote: fatal: Invalid revision range 0000000000000000000000000000000000000000..567a54a227a31d074c7470bc4a9969be320dd212
remote: Stopping DIY cartridge
remote: Building git ref 'master', commit a03b676
remote: Preparing build for deployment
remote: Prepared deployment artifacts in /var/lib/openshift/525532196948fa5632000144/app-deployments/2013-10-09_06-39-52.732
remote: Deployment id is 19d41549
remote: Activating deployment
remote: Result: success
remote: Activation status: success
remote: Deployment completed
To ssh://525532196948fa5632000144.rhcloud.com/~/git/d1.git/
 * [new branch]      br1 -> br1
Branch br1 set up to track remote branch br1 from origin.

Access the app's webpage, the content added in branch 'br1' is not deployed to the app

Expected results:
Should have auto deployed the branch 'br1' to the application

Additional info:

Comment 1 Andy Goldstein 2013-10-11 19:23:52 UTC
https://github.com/openshift/origin-server/pull/3861

Comment 2 openshift-github-bot 2013-10-11 21:04:24 UTC
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/a464c503709b1099d2ebf4f708a647294cd662bf
Deploy fixes

Don't update metadata.json on disk for each attr update

Make all 3 jenkins_shell_command files consistent

Only check for marker files when using git push or jenkins remotedeploy

Support checking for marker files in the correct deployment ref

Bug 1017154
Bug 1013064

Comment 3 Jakub Hadvig 2013-10-12 15:09:00 UTC
Hi Andy,
closed the my PR because of the duplication. 

https://github.com/openshift/origin-server/pull/3837

Comment 4 Jianwei Hou 2013-10-14 02:53:56 UTC
Verified on devenv_3893
After git push, the branch can be deployed properly now.


Note You need to log in before you can comment on or make changes to this bug.