0

I have a DSL script that creates a job. As soon as I run the job the config.xml is changed. Because of this, the job doesn't get an update when I run the seed job again.

I suspect some plugins do this. Can you tell me the best way to find out what changes the config when the job is run?

[
    [name: "Sonar/co", repo: "repo.git", pomPath: "pom.xml", branch: "development", mvnGoal: "-am -P dev -pl project clean test"]
].each { Map config ->
    mavenJob(config.name) {
        description "Sonar job für ${config.name}"

        logRotator {
            numToKeep(1)
        }

        label "sonar"

        scm {
            git {
                branch "*/${config.branch}"
                remote {
                    url "git@repository:${config.repo}"
                }
                browser {
                    gitLab("https://gitlab.DOMAIN.de/", "9.0")
                }
            }
        }

        mavenInstallation "maven339"
        goals config.mvnGoal
        rootPOM config.pomPath

       configure { node ->
            node / settings (class: 'jenkins.mvn.DefaultSettingsProvider') {
            }
            node / globalSettings (class: 'jenkins.mvn.DefaultGlobalSettingsProvider') {
            }            
        }


    }
}
T3rm1
  • 2,299
  • 5
  • 34
  • 51

0 Answers0