Publish site reports

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      Maven projects automatically archive Maven-generated sites. The site is served under job/<job-name>/site/. It would be great if it would be possible to do the same by withMaven, example:

      stage('Build Docs') {
        steps {
          withMaven(publisherStrategy: 'EXPLICIT' options: [
            sitePublisher(disabled: false)
          ]) {
            sh "mvn site"
          }
        }
      }
      

      Now I use the following workaround:

      stage('Build Docs') {
        steps {
          withMaven(publisherStrategy: 'EXPLICIT' options: [
            sitePublisher(disabled: false)
          ]) {
            sh "mvn site"
          }
          dir('target') {
            archiveArtifacts artifacts: 'site/**'
          }
        }
      }
      

      Documentation is available under:
      job/<job-name>/job/<branch-name>/lastSuccessfulBuild/artifact/site/ (user is forced to click index.html).

            Assignee:
            Benoit
            Reporter:
            Adam Gabryś
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: