Merge "CloudBees Docker Build and Publish plugin added"

This commit is contained in:
Jenkins 2016-05-31 16:11:44 +00:00 committed by Gerrit Code Review
commit a02dd616a7
5 changed files with 77 additions and 0 deletions

View File

@ -23,6 +23,9 @@ Properties:
cfplugin:
Contract: $.bool()
Default: false
dockerplugin:
Contract: $.bool()
Default: false
gitUser:
Contract: $.string()
gitEmail:
@ -70,6 +73,12 @@ Methods:
- $template: $resources.yaml('InstallCFPlugin.template')
- $.instance.agent.call($template, $resources)
- If: $.dockerplugin
Then:
- $._environment.reporter.report($this, 'Installing Docker Build and Publish plugin...')
- $template: $resources.yaml('InstallDockerPlugin.template')
- $.instance.agent.call($template, $resources)
- If: $.gitUser != null and $.gitEmail != null
Then:
- $.configureGitPlugin($.gitUser, $.gitEmail)

View File

@ -0,0 +1,17 @@
FormatVersion: 2.1.0
Version: 1.0.0
Name: Deploy Jenkins
Body: |
return install_plugin().stdout
Scripts:
install_plugin:
Type: Application
Version: 1.0.0
EntryPoint: install_docker_plugin.sh
Files: ['docker_plugin.pp']
Options:
captureStdout: true
captureStderr: true

View File

@ -0,0 +1,40 @@
node default {
service { 'jenkins':
ensure => running,
enable => true,
}
jenkins::plugin { 'credentials':
notify => Service['jenkins']
}
jenkins::plugin { 'icon-shim':
notify => Service['jenkins']
}
jenkins::plugin { 'token-macro':
notify => Service['jenkins']
}
jenkins::plugin { 'authentication-tokens':
notify => Service['jenkins'],
require => Jenkins::Plugin['credentials']
}
jenkins::plugin { 'docker-commons':
notify => Service['jenkins'],
require => [
Jenkins::Plugin['authentication-tokens'],
Jenkins::Plugin['icon-shim'],
Jenkins::Plugin['credentials']
]
}
jenkins::plugin { 'docker-build-publish':
notify => Service['jenkins'],
require => [
Jenkins::Plugin['token-macro'],
Jenkins::Plugin['docker-commons']
]
}
}

View File

@ -0,0 +1,3 @@
#!/bin/bash
puppet apply docker_plugin.pp

View File

@ -7,6 +7,7 @@ Application:
ldap: $.appConfiguration.OpenLDAP
gerrit: $.appConfiguration.Gerrit
cfplugin: $.appConfiguration.cfplugin
dockerplugin: $.appConfiguration.dockerplugin
gitUser: $.appConfiguration.gitUser
gitEmail: $.appConfiguration.gitEmail
instance:
@ -36,6 +37,13 @@ Forms:
Select to true to install CF Plugin automatically
initial: false
required: false
- name: dockerplugin
type: boolean
label: CloudBees Docker Build and Publish plugin
description: >-
Select to true to install Docker Build and Publish plugin automatically
initial: false
required: false
- name: assignFloatingIP
type: boolean
label: Assign Floating IP