title: How to define BuildConfig object with Jenkins and openshift
body: <p>I am using Jenkins and OpenShift to create the build and trigger the deployment. The following is my YAML file :</p>
  
  <pre><code>apiVersion: v1
  kind: List
  metadata: {}
  items:
  - apiVersion: v1
    kind: BuildConfig
    metadata:
      name: petclinic-pipeline
    spec:
      source:
        git:
         uri: &lt;&lt;git url&gt;&gt;
        type: Git
      strategy:
        type: JenkinsPipeline
        jenkinsPipelineStrategy:
          jenkinsfilePath: Jenkinsfile
      triggers:
      - generic:
          secret: FiArdDBH
        type: Generic
  </code></pre>
  
  <p>The Jenkins config is as follows:</p>
  
  <pre><code>node {
    stage('Source Checkout') {
      git url: "git url"
    }
  
     stage('Build') {
        git url: "git url"
        sh "/var/lib/jenkins/apache-maven-3.5.4/bin/mvn clean package -Dorg.jenkinsci.plugins.durabletask.BourneShellScript.HEARTBEAT_CHECK_INTERVAL=300 -DskipTests=true"
        stash name:"jar", includes:"target/a.jar"
      }
  
    stage('Build Image') {
      unstash name:"jar"
      sh "oc start-build petclinic-pipeline --from-file=target/a.jar --follow"
    }
   } 
  </code></pre>
  
  <p>Now, if I apply this, I'm getting the following error :</p>
  
  <pre><code>$ oc start-build petclinic-pipeline --from-file=target/a.jar --follow
  Uploading file "target/a.jar" as binary input for the build ... The
  Build "petclinic-pipeline-20" is invalid: spec.source.git: Invalid
  value: "": must be set when using Jenkins Pipeline strategy with
  Jenkinsfile from a git repo
  </code></pre>
  
  <p>My expectation is that the image should be built and I am not able to understand where the issue is. Is it something like, spec source git should not be used in YAML file when using Jenkins strategy?</p>