Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-46275

Jenkins Cloudfoundry plugin not binding service when using groovy pipeline DSl

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • cloudfoundry-plugin
    • None
    • Jenkins-Version 2.46.2
      Cloud Foundry Plugin Version: 2.1.1

    Description

      When using jenkins pipeline step to push an app to cloudfoundry, services are not binding to the app. The app starts fine but the service is not bound. I am using Manifest choice. The same configs on maven job are working fine.

      Attachments

        Activity

          sworisbreathing Steven Swor added a comment - - edited

          nikhiljain14 - I suspect this has to do with the way the service list is declared in the jenkinsfile, and what data type the collection is meant to be. Can you try changing

          def serviceList = ["mysql-service"]
          

          to

          def serviceList = [["$class": "com.hpe.cloudfoundryjenkins.CloudFoundryPushPublisher$ServiceName", name: "mysql-service"]]
          
          sworisbreathing Steven Swor added a comment - - edited nikhiljain14 - I suspect this has to do with the way the service list is declared in the jenkinsfile, and what data type the collection is meant to be. Can you try changing def serviceList = [ "mysql-service" ] to def serviceList = [[ "$class" : "com.hpe.cloudfoundryjenkins.CloudFoundryPushPublisher$ServiceName" , name: "mysql-service" ]]
          nikhiljain14 Nikhil Jain added a comment -

          sworisbreathing Specifying it his way also did not help. The app deploys but no service is bound to the app.

          nikhiljain14 Nikhil Jain added a comment - sworisbreathing Specifying it his way also did not help. The app deploys but no service is bound to the app.

          People

            sworisbreathing Steven Swor
            nikhiljain14 Nikhil Jain
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: