Puppet Class: profile::ci::proxy_jenkins

Defined in:
modules/profile/manifests/ci/proxy_jenkins.pp

Overview

Class contint::proxy_jenkins

A http proxy in front of Jenkins

http_port

HTTP port for a Jenkins instance webservice. Example: 8080

prefix

The HTTP path used to reach the Jenkins instance. Must have a leading slash. Example: /ci

Parameters:

  • http_port (Any) (defaults to: hiera('profile::ci::proxy_jenkins::http_port'))
  • prefix (Any) (defaults to: hiera('profile::ci::proxy_jenkins::prefix'))


12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# File 'modules/profile/manifests/ci/proxy_jenkins.pp', line 12

class profile::ci::proxy_jenkins (
    $http_port = hiera('profile::ci::proxy_jenkins::http_port'),
    $prefix = hiera('profile::ci::proxy_jenkins::prefix'),
) {

  # run jenkins behind Apache and have pretty URLs / proxy port 80
  # https://wiki.jenkins-ci.org/display/JENKINS/Running+Jenkins+behind+Apache

  file {
    '/etc/apache2/conf.d/jenkins_proxy':
      ensure => absent,
  }

  file {
    '/etc/apache2/jenkins_proxy':
      owner   => 'root',
      group   => 'root',
      mode    => '0444',
      content => template('contint/apache/proxy_jenkins.erb'),
  }

}