Bug 1252822 - [origin_devexp_555]When push to origin-gitserver there is always a error tip info
[origin_devexp_555]When push to origin-gitserver there is always a error tip ...
Product: OpenShift Origin
Classification: Red Hat
Component: Build (Show other bugs)
Unspecified Unspecified
medium Severity low
: ---
: ---
Assigned To: Cesar Wong
Wenjing Zheng
Depends On:
  Show dependency treegraph
Reported: 2015-08-12 05:57 EDT by DeShuai Ma
Modified: 2016-09-19 09:53 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2016-09-19 09:53:49 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description DeShuai Ma 2015-08-12 05:57:14 EDT
Description of problem:
When push to origin-gitserver, the push can be succeed, but there is alway a error tip info. "remote: Error in configuration: default cluster has no server defined"

Version-Release number of selected component (if applicable):
openshift v1.0.4-184-gc5f08bc-dirty
kubernetes v1.1.0-alpha.0-1155-gb73c53c

How reproducible:

Steps to Reproduce:
1.Configure gitserver without auth, set both "REQUIRE_SERVER_AUTH" and "REQUIRE_GIT_AUTH" to empty.
$ cat examples/gitserver/gitserver.yaml

2.Deploy the private gitserver
$ oc create -f gitserver.yaml -n dma1

3.Clone the repo from private gitserver and make some change push to gitserver
$ git clone
$ cd ruby-sample-build
$ echo "hello" > b.txt
$ git add b.txt
$ git commit -anmq
$ git push

Actual results:
3.There is a error tip info "remote: Error in configuration: default cluster has no server defined".
[fedora@ip-10-154-3-36 ruby-sample-build]$ git push
warning: push.default is unset; its implicit value has changed in
Git 2.0 from 'matching' to 'simple'. To squelch this message
and maintain the traditional behavior, use:

  git config --global push.default matching

To squelch this message and adopt the new behavior now, use:

  git config --global push.default simple

When push.default is set to 'matching', git will push local branches
to the remote branches that already exist with the same name.

Since Git 2.0, Git defaults to the more conservative 'simple'
behavior, which only pushes the current branch to the corresponding
remote branch that 'git pull' uses to update the current branch.

See 'git help config' and search for 'push.default' for further information.
(the 'simple' mode was introduced in Git 1.7.11. Use the similar mode
'current' instead of 'simple' if you sometimes use older versions of Git)

Counting objects: 3, done.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (3/3), 302 bytes | 0 bytes/s, done.
Total 3 (delta 1), reused 0 (delta 0)
remote: detect: found language openshift/ruby for ruby-sample-build
remote: Error in configuration: default cluster has no server defined
   65b3d6b..a8372b2  master -> master

Expected results:
3.Should no error tip

Additional info:
Comment 1 Clayton Coleman 2015-08-20 22:51:57 EDT
Ok, we need to set a KUBECONFIG for the local environment (KUBECONFIG='-') so that it picks up the right variables.
Comment 2 Cesar Wong 2016-04-28 09:51:51 EDT
The gitserver service account should now be able to invoke new-app or start a new build as long as it is assigned the 'edit' role. Please see doc at:
Comment 3 XiuJuan Wang 2016-04-28 23:16:26 EDT
No error when the push code to gitserver with openshift/origin-gitserver (d4413378d01d).

Total 267 (delta 88), reused 267 (delta 88)
remote: --> Found Docker image 7666c51 (2 weeks old) from Docker Hub for "centos/ruby-22-centos7"
remote:     Ruby 2.2 
remote:     -------- 
remote:     Platform for building and running Ruby 2.2 applications
remote:     Tags: builder, ruby, ruby22
remote:     * An image stream will be created as "ruby-22-centos7:latest" that will track the source image
remote:     * A Docker build using source code from http://git:8080/ruby-hello-world.git will be created
remote:       * The resulting image will be pushed to image stream "ruby-hello-world:latest"
remote:       * Every time "ruby-22-centos7:latest" changes a new build will be triggered
remote:     * This image will be deployed in deployment config "ruby-hello-world"
remote:     * Port 8080 will be load balanced by service "ruby-hello-world"
remote:       * Other containers can access this service through the hostname "ruby-hello-world"
remote: --> Creating resources with label app=ruby-hello-world ...
remote:     imagestream "ruby-22-centos7" created
remote:     imagestream "ruby-hello-world" created
remote:     buildconfig "ruby-hello-world" created
remote:     deploymentconfig "ruby-hello-world" created
remote:     service "ruby-hello-world" created
remote: --> Success
remote:     Build scheduled, use 'oc logs -f bc/ruby-hello-world' to track its progress.
remote:     Run 'oc status' to view your app.
To http://git-xiuwang.0428-og3.qe.rhcloud.com/ruby-hello-world.git
 * [new branch]      master -> master

$ git push openshift master 
Counting objects: 4, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (2/2), done.
Writing objects: 100% (3/3), 253 bytes | 0 bytes/s, done.
Total 3 (delta 1), reused 0 (delta 0)
remote: build: started on build configuration 'ruby-hello-world'
To http://git-xiuwang.0428-og3.qe.rhcloud.com/ruby-hello-world.git
   e79d887..6d24ed5  master -> master

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