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

Add support for Jenkins Pipeline

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

        Attachments

          Activity

          Hide
          recampbell Ryan Campbell added a comment -

          Suresh Kumar, are you actively working on this? Alex Johnson has a WIP PR at deploy-plugin#25. Do you mind if we repurpose this issue to pull in the acceptance criteria, which we see as the following:

           

          As a pipeline author, I would like to use the Jenkins Deployer plugin from within my pipeline scripts and declarative pipelines so that I can easily deploy my apps from my Jenkins pipeline and  migrate my freestyle usage of this plugin to pipeline.

          Acceptance Criteria

          1. Each of the supported container adapters will have a symbol that allows creation of references which includes the deployment details required by each deployment target
          2. There will be a pipeline step called deploy that is configurable from within the pipeline script
          3. There will be unit tests that confirm new functionality
          4. There will be manual testing that deploys wars from the pipeline (preferably both Tomcat and Glassfish)
          5. The plugin will be upgraded to a recent plugin pom so that the testing is performed against somewhat recent versions

          I'm proposing the following syntax, I think this provides a reasonably straightforward use and config.

          node { 
              def tc8 = tomcat8( 
                  url:        'http://localhost:1234/app',
                  password:   '******', 
                  userName:   'admin'
              )
              deploy(container: tc8, war: '/target/app.war', contextPath: '/app')   
              deploy(containers: [tc8, gf3], war: '/target/app.war', contextPath: '/app')
          }

           

          Tech notes/tasks:

          • Refactor to work with pipeline APIs
          Show
          recampbell Ryan Campbell added a comment - Suresh Kumar , are you actively working on this? Alex Johnson has a WIP PR at deploy-plugin#25 . Do you mind if we repurpose this issue to pull in the acceptance criteria, which we see as the following:   As a pipeline author, I would like to use the Jenkins Deployer plugin from within my pipeline scripts and declarative pipelines so that I can easily deploy my apps from my Jenkins pipeline and  migrate my freestyle usage of this plugin to pipeline. Acceptance Criteria Each of the supported container adapters will have a symbol that allows creation of references which includes the deployment details required by each deployment target There will be a pipeline step called deploy that is configurable from within the pipeline script There will be unit tests that confirm new functionality There will be manual testing that deploys wars from the pipeline (preferably both Tomcat and Glassfish) The plugin will be upgraded to a recent plugin pom so that the testing is performed against somewhat recent versions I'm proposing the following syntax, I think this provides a reasonably straightforward use and config. node { def tc8 = tomcat8( url: 'http: //localhost:1234/app' , password: '******' , userName: 'admin' ) deploy(container: tc8, war: '/target/app.war' , contextPath: '/app' ) deploy(containers: [tc8, gf3], war: '/target/app.war' , contextPath: '/app' ) }   Tech notes/tasks: Refactor to work with pipeline APIs
          Hide
          pskumar448 Suresh Kumar added a comment -

          Before working on this functionality I didn't look at PR list, past 2 months onwards I was thinking to implement last weekend I got time and implemented. After sending the PR only I got to know there is already a PR for this functionality.

          Show
          pskumar448 Suresh Kumar added a comment - Before working on this functionality I didn't look at PR list, past 2 months onwards I was thinking to implement last weekend I got time and implemented. After sending the PR only I got to know there is already a PR for this functionality.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Leandro Kersting de Freitas
          Path:
          pom.xml
          src/main/java/hudson/plugins/deploy/CargoContainerAdapter.java
          src/main/java/hudson/plugins/deploy/ContainerAdapter.java
          src/main/java/hudson/plugins/deploy/DefaultCargoContainerAdapterImpl.java
          src/main/java/hudson/plugins/deploy/DeployPublisher.java
          src/main/java/hudson/plugins/deploy/PasswordProtectedAdapterCargo.java
          src/main/java/hudson/plugins/deploy/glassfish/GlassFish2xAdapter.java
          src/main/java/hudson/plugins/deploy/glassfish/GlassFish3xAdapter.java
          src/main/java/hudson/plugins/deploy/jboss/JBoss3xAdapter.java
          src/main/java/hudson/plugins/deploy/jboss/JBoss4xAdapter.java
          src/main/java/hudson/plugins/deploy/jboss/JBoss5xAdapter.java
          src/main/java/hudson/plugins/deploy/jboss/JBoss6xAdapter.java
          src/main/java/hudson/plugins/deploy/jboss/JBoss7xAdapter.java
          src/main/java/hudson/plugins/deploy/tomcat/Tomcat4xAdapter.java
          src/main/java/hudson/plugins/deploy/tomcat/Tomcat5xAdapter.java
          src/main/java/hudson/plugins/deploy/tomcat/Tomcat6xAdapter.java
          src/main/java/hudson/plugins/deploy/tomcat/Tomcat7xAdapter.java
          src/main/java/hudson/plugins/deploy/tomcat/Tomcat8xAdapter.java
          src/main/java/hudson/plugins/deploy/tomcat/TomcatAdapter.java
          src/main/resources/hudson/plugins/deploy/DeployPublisher/config.jelly
          src/test/java/hudson/plugins/deploy/LegacyAbstractProjectOnlyAdapter.java
          src/test/java/hudson/plugins/deploy/PipelineSyntaxTest.java
          src/test/java/hudson/plugins/deploy/RemoteCallableTest.java
          src/test/java/hudson/plugins/deploy/WorkflowCompatibleAdapter.java
          src/test/java/hudson/plugins/deploy/glassfish/GlassFish3xAdapterTest.java
          http://jenkins-ci.org/commit/deploy-plugin/27b805ae70a9a007c800d8b65dfb739e4293bf84
          Log:
          Merge pull request #28 from alexbrjo/rebase-pipeline-compat

          JENKINS-44810 Pipeline Compatibility, again

          Compare: https://github.com/jenkinsci/deploy-plugin/compare/53e1f32cd9db...27b805ae70a9

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Leandro Kersting de Freitas Path: pom.xml src/main/java/hudson/plugins/deploy/CargoContainerAdapter.java src/main/java/hudson/plugins/deploy/ContainerAdapter.java src/main/java/hudson/plugins/deploy/DefaultCargoContainerAdapterImpl.java src/main/java/hudson/plugins/deploy/DeployPublisher.java src/main/java/hudson/plugins/deploy/PasswordProtectedAdapterCargo.java src/main/java/hudson/plugins/deploy/glassfish/GlassFish2xAdapter.java src/main/java/hudson/plugins/deploy/glassfish/GlassFish3xAdapter.java src/main/java/hudson/plugins/deploy/jboss/JBoss3xAdapter.java src/main/java/hudson/plugins/deploy/jboss/JBoss4xAdapter.java src/main/java/hudson/plugins/deploy/jboss/JBoss5xAdapter.java src/main/java/hudson/plugins/deploy/jboss/JBoss6xAdapter.java src/main/java/hudson/plugins/deploy/jboss/JBoss7xAdapter.java src/main/java/hudson/plugins/deploy/tomcat/Tomcat4xAdapter.java src/main/java/hudson/plugins/deploy/tomcat/Tomcat5xAdapter.java src/main/java/hudson/plugins/deploy/tomcat/Tomcat6xAdapter.java src/main/java/hudson/plugins/deploy/tomcat/Tomcat7xAdapter.java src/main/java/hudson/plugins/deploy/tomcat/Tomcat8xAdapter.java src/main/java/hudson/plugins/deploy/tomcat/TomcatAdapter.java src/main/resources/hudson/plugins/deploy/DeployPublisher/config.jelly src/test/java/hudson/plugins/deploy/LegacyAbstractProjectOnlyAdapter.java src/test/java/hudson/plugins/deploy/PipelineSyntaxTest.java src/test/java/hudson/plugins/deploy/RemoteCallableTest.java src/test/java/hudson/plugins/deploy/WorkflowCompatibleAdapter.java src/test/java/hudson/plugins/deploy/glassfish/GlassFish3xAdapterTest.java http://jenkins-ci.org/commit/deploy-plugin/27b805ae70a9a007c800d8b65dfb739e4293bf84 Log: Merge pull request #28 from alexbrjo/rebase-pipeline-compat JENKINS-44810 Pipeline Compatibility, again Compare: https://github.com/jenkinsci/deploy-plugin/compare/53e1f32cd9db...27b805ae70a9
          Hide
          jansohn Robin Jansohn added a comment -

          Can you please create a new release and close this ticket as this has been already merged in 2017?

          Show
          jansohn Robin Jansohn added a comment - Can you please create a new release and close this ticket as this has been already merged in 2017?
          Hide
          jansohn Robin Jansohn added a comment -

          Fixed in master. Will be released soon (next week) in new version 1.14.

          Show
          jansohn Robin Jansohn added a comment - Fixed in master. Will be released soon (next week) in new version 1.14.

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            pskumar448 Suresh Kumar
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: