Bug 1365440 - Better to improve output warning when start build from a git repository via "oc start-build" without git installed
Summary: Better to improve output warning when start build from a git repository via "...
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 3.3.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: ---
Assignee: Cesar Wong
QA Contact: Xingxing Xia
Depends On:
TreeView+ depends on / blocked
Reported: 2016-08-09 09:35 UTC by Dongbo Yan
Modified: 2016-09-27 09:43 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2016-09-27 09:43:01 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1933 normal SHIPPED_LIVE Red Hat OpenShift Container Platform 3.3 Release Advisory 2016-09-27 13:24:36 UTC

Description Dongbo Yan 2016-08-09 09:35:54 UTC
Description of problem:
When git is not installed in local, cannot start build from a git repository using "oc start-build --from-repo=" command.It's better to improve output warning.
Version-Release number of selected component (if applicable):
openshift v3.3.0.17
kubernetes v1.3.0+507d3a7
etcd 2.3.0+git

How reproducible:

Steps to Reproduce:
1.Make sure git is not installed
 $ rpm -e --nodeps git
2.Clone a source code repo to localhost
 $ git clone https://github.com/openshift/ruby-hello-world
3.Create an application via "oc new-app"
 $ cd ruby-hello-world
 $ oc new-app .
4.Start new build
 $ oc start-build ruby-22-centos7 --from-repo=.

Actual results:
3.Will create a binary build
4.cannot start new build with error output
Uploading "." at commit "HEAD" as binary input for the build ...
error: the directory "." is not a valid Git repository: git binary not available

Expected results:
4.error output:
Git repository is valid, but please make sure git is installed. Git is required to work with git repositories

Additional info:

Comment 1 Cesar Wong 2016-08-12 22:04:18 UTC
PR https://github.com/openshift/origin/pull/10397

Comment 2 Troy Dawson 2016-08-18 16:32:55 UTC
This has been merged into ose and is in OSE v3.3.0.22 or newer.

Comment 4 Dongbo Yan 2016-08-19 11:02:47 UTC

$oc start-build ruby-22-centos7 --from-repo=.
error: cannot find git. Git is required to start a build from a repository. If git is not available, use --from-dir instead.

openshift v3.3.0.22
kubernetes v1.3.0+507d3a7
etcd 2.3.0+git

Comment 6 errata-xmlrpc 2016-09-27 09:43:01 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


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