diff --git a/modules/jenkins_jobs/manifests/add_jobs.pp b/modules/jenkins_jobs/manifests/add_jobs.pp index 4e0c22dda3..0e48fd9b4b 100644 --- a/modules/jenkins_jobs/manifests/add_jobs.pp +++ b/modules/jenkins_jobs/manifests/add_jobs.pp @@ -74,7 +74,7 @@ define jenkins_jobs::add_jobs($site) { jenkins_jobs::job { "${name}-venv": site => "${site}", - project => "${job}", + project => "${name}", job => "venv", triggers => template("jenkins_jobs/trigger_timed_midnight.xml.erb"), builders => template("jenkins_jobs/builder_venv.xml.erb"), diff --git a/modules/jenkins_jobs/manifests/job.pp b/modules/jenkins_jobs/manifests/job.pp index 53029130e8..4983ed423c 100644 --- a/modules/jenkins_jobs/manifests/job.pp +++ b/modules/jenkins_jobs/manifests/job.pp @@ -3,42 +3,34 @@ define jenkins_jobs::job($site, $project, $job, $triggers="", $builders, $publis file { "/var/lib/jenkins/jobs/${project}-${job}": ensure => directory, owner => 'jenkins', - group => 'nogroup' } file { "/var/lib/jenkins/jobs/${project}-${job}/builds": ensure => directory, owner => 'jenkins', - group => 'nogroup', - require => File["/var/lib/jenkins/jobs/${project}-${job}"], - notify => Service["jenkins"] + require => File["/var/lib/jenkins/jobs/${project}-${job}"] } file { "/var/lib/jenkins/jobs/${project}-${job}/config-history": ensure => directory, owner => 'jenkins', - group => 'nogroup', - require => File["/var/lib/jenkins/jobs/${project}-${job}"], - notify => Service["jenkins"] + require => File["/var/lib/jenkins/jobs/${project}-${job}"] } file { "/var/lib/jenkins/jobs/${project}-${job}/config.xml": ensure => present, content => template("jenkins_jobs/body.xml.erb"), owner => 'jenkins', - group => 'nogroup', require => File["/var/lib/jenkins/jobs/${project}-${job}"], notify => Service["jenkins"] } - file { "/var/lib/jenkins/jobs/${project}-${job}/nextBuildNumer": + file { "/var/lib/jenkins/jobs/${project}-${job}/nextBuildNumber": ensure => present, content => "1", owner => 'jenkins', - group => 'nogroup', replace => false, - require => File["/var/lib/jenkins/jobs/${project}-${job}"], - notify => Service["jenkins"] + require => File["/var/lib/jenkins/jobs/${project}-${job}"] } } diff --git a/modules/jenkins_jobs/templates/body.xml.erb b/modules/jenkins_jobs/templates/body.xml.erb index 14a6719195..954c37681e 100644 --- a/modules/jenkins_jobs/templates/body.xml.erb +++ b/modules/jenkins_jobs/templates/body.xml.erb @@ -50,10 +50,10 @@ <%= builders %> <% end %> - <% if publishers != "" %> + <% if publishers != "" %> <%= publishers %> - <% end %> +