freeStyleJob('__seed-job') {
    logRotator {
        numToKeep(30)
    }
    triggers {
        scm('* * * * *')
    }
    wrappers {
        timestamps()
    }
    scm {
        git {
            remote {
                url('https://github.com/unguiculus/job-dsl-sample.git')
                name('origin')
            }
            branch('origin/master')
            extensions {
                localBranch('master')
            }
        }
    }
    steps {
        dsl {
            additionalClasspath('src/main/groovy')
            external('jobs/jobs.groovy')
            ignoreExisting(false)
            lookupStrategy('JENKINS_ROOT')
            removeAction('DELETE')
            removeViewAction('DELETE')
        }
    }
}

multibranchPipelineJob('__seed-job') {
    branchSources {
        github {
            repoOwner('unguiculus')
            repository('job-dsl-sample')
            buildForkPRHead(false)
            buildForkPRMerge(true)
            buildOriginBranch(true)
            buildOriginBranchWithPR(false)
            buildOriginPRHead(false)
            buildOriginPRMerge(true)
        }
    }
    orphanedItemStrategy {
        discardOldItems {
            daysToKeep(0)
            numToKeep(0)
        }
    }
    triggers {
        periodic(1)
    }
}

Use multi-branch pipeline for seed job
Use multi-branch pipeline for seed job
