Skip to content
This repository was archived by the owner on Aug 29, 2018. It is now read-only.

Commit 4d6f544

Browse files
committed
Module overhaul for performance and extensibility
1 parent 4e6e368 commit 4d6f544

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+848
-1035
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
.DS_Store
2+
.project
23
.vagrant
34
metadata.json
45
*~
56
*.swp
7+
pkg

Modulefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
11
name 'openshift-openshift_origin'
2-
version '3.0.1'
2+
version '4.0.0'
33

44
author 'Mojo Lingo, Red Hat'
55
license 'ASL'
66
project_page 'https://github.com/kraman/puppet-openshift_origin'
77
source 'git://github.com/openshift/puppet-openshift_origin.git'
88
summary 'Module for installing Red Hat Openshift'
99
description 'Configures OpenShift Origin broker, nodes and support servers'
10+
dependency 'rharrison/lokkit', '>=0.2.0'
1011
dependency 'puppetlabs/ntp', '>=0.1.0'
1112
dependency 'puppetlabs/stdlib', '>=2.6.0'
13+
dependency 'blentz/selinux_types', '>=0.1.0'
14+
dependency 'duritong/sysctl', '>=0.0.1'

README.asciidoc

Lines changed: 37 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -45,36 +45,36 @@ this class.
4545

4646
http://docs.puppetlabs.com/guides/parameterized_classes.html[Using Parameterized Classes]
4747

48-
.Example: Single host (broker+console+node) which uses the Avahi MDNS and mongo Auth plugin:
48+
.Example: Single host (broker+console+node) which uses the Avahi MDNS and htpasswd Auth plugin:
4949
----
5050
class { 'openshift_origin' :
51-
domain => 'example.com',
52-
node_unmanaged_users => ['root'],
53-
development_mode => true,
54-
conf_node_external_eth_dev => 'eth0',
55-
install_method => 'yum',
56-
register_host_with_named => true,
57-
broker_auth_plugin => 'mongo',
58-
broker_dns_plugin => 'avahi',
51+
domain => 'example.com',
52+
node_unmanaged_users => ['root'],
53+
development_mode => true,
54+
conf_node_external_eth_dev => 'eth0',
55+
install_method => 'yum',
56+
register_host_with_nameserver => true,
57+
broker_auth_plugin => 'htpasswd',
58+
broker_dns_plugin => 'avahi',
5959
}
6060
----
6161

6262
.Example: Single host (broker+console+node) which uses the **Kerberos** Auth plugin and GSS-TSIG.
6363
----
6464
class { 'openshift_origin' :
65-
domain => 'example.com',
66-
node_unmanaged_users => ['root'],
67-
development_mode => true,
68-
conf_node_external_eth_dev => 'eth0',
69-
install_method => 'yum',
70-
register_host_with_named => true,
71-
broker_auth_plugin => 'remote-user',
72-
broker_dns_plugin => 'named',
73-
bind_krb_principal => $hostname,
74-
bind_krb_keytab => '/etc/dns.keytab'
75-
broker_krb_keytab => '/etc/http.keytab',
76-
broker_krb_auth_realms => 'EXAMPLE.COM',
77-
broker_krb_service_name => $hostname,
65+
domain => 'example.com',
66+
node_unmanaged_users => ['root'],
67+
development_mode => true,
68+
conf_node_external_eth_dev => 'eth0',
69+
install_method => 'yum',
70+
register_host_with_nameserver => true,
71+
broker_auth_plugin => 'remote-user',
72+
broker_dns_plugin => 'nsupdate',
73+
bind_krb_principal => $hostname,
74+
bind_krb_keytab => '/etc/dns.keytab'
75+
broker_krb_keytab => '/etc/http.keytab',
76+
broker_krb_auth_realms => 'EXAMPLE.COM',
77+
broker_krb_service_name => $hostname,
7878
}
7979
----
8080

@@ -107,13 +107,13 @@ $ d.register_application "appname", "namespace", "node_fqdn"
107107

108108
Choose from the following roles to be configured on this node.
109109

110-
* broker - Installs the broker and console.
111-
* node - Installs the node and cartridges.
112-
* activemq - Installs activemq message broker.
113-
* datastore - Installs MongoDB (not sharded/replicated)
114-
* named - Installs a BIND dns server configured with a TSIG key for updates.
110+
* broker - Installs the broker and console.
111+
* node - Installs the node and cartridges.
112+
* msgserver - Installs ActiveMQ message broker.
113+
* datastore - Installs MongoDB (not sharded/replicated)
114+
* nameserver - Installs a BIND dns server configured with a TSIG key for updates.
115115

116-
Default: ['broker','node','activemq','datastore','named']
116+
Default: ['broker','node','msgserver','datastore','nameserver']
117117

118118
==== install_method
119119
Choose from the following ways to provide packages:
@@ -189,11 +189,11 @@ Default: example.com
189189

190190
==== broker_hostname
191191
==== node_hostname
192-
==== named_hostname
193-
==== activemq_hostname
192+
==== nameserver_hostname
193+
==== msgserver_hostname
194194
==== datastore_hostname
195195
Default: the root plus the domain, e.g. broker.example.com - except
196-
named=ns1.example.com
196+
nameserver=ns1.example.com
197197

198198
These supply the FQDN of the hosts containing these components. Used
199199
for configuring the host's name at install, and also for configuring
@@ -204,8 +204,8 @@ DNS entries for the hostnames of the other components being
204204
installed on this host as well. If you are using a nameserver set
205205
up separately, you are responsible for all necessary DNS entries.
206206

207-
==== named_ip_addr
208-
Default: IP of a named instance or current IP if installing on this
207+
==== nameserver_ip_addr
208+
Default: IP of a name server instance or current IP if installing on this
209209
node. This is used by every node to configure its primary name server.
210210

211211
Default: the current IP (at install)
@@ -223,8 +223,8 @@ can be used instead of the HMAC-MD5 key for updates.
223223
When the nameserver is remote, this Kerberos principal together with
224224
Kerberos keytab can be used instead of the HMAC-MD5 key for updates.
225225

226-
==== conf_named_upstream_dns
227-
List of upstream DNS servers to use when installing named on this node.
226+
==== conf_nameserver_upstream_dns
227+
List of upstream DNS servers to use when installing a nameserver on this node.
228228

229229
Default: ['8.8.8.8']
230230

@@ -263,7 +263,7 @@ Default: ['time.apple.com iburst', 'pool.ntp.org iburst', 'clock.redhat.com ibur
263263
NOTE: Use iburst after every ntp server definition to speed up the
264264
initial synchronization.
265265

266-
==== activemq_admin_password
266+
==== msgserver_admin_password
267267
This is the admin password for the ActiveMQ admin console, which is
268268
not needed by OpenShift but might be useful in troubleshooting.
269269

@@ -429,7 +429,7 @@ Default: false
429429
Install a Getty shell which displays DNS, IP and login information. Used for
430430
all-in-one VM installation.
431431

432-
==== register_host_with_named
432+
==== register_host_with_nameserver
433433
Setup DNS entries for this host in a locally installed bind DNS instance.
434434

435435
Default: false

configure_origin.pp.broker_example

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
class { 'openshift_origin' :
22
# Components to install on this host:
3-
roles => ['broker','named','activemq','datastore'],
3+
roles => ['broker','nameserver','msgserver','datastore'],
44

55
# BIND / named config
66
# This is the key for updating the OpenShift BIND server
7-
bind_key => '<DNSSEC_BIND_KEY>',
7+
bind_key => '<DNSSEC_BIND_KEY>',
88
# The domain under which applications should be created.
9-
domain => 'example.com',
9+
domain => 'example.com',
1010
# Apps would be named <app>-<namespace>.example.com
1111
# This also creates hostnames for local components under our domain
12-
register_host_with_named => true,
12+
register_host_with_nameserver => true,
1313
# Forward requests for other domains (to Google by default)
14-
conf_named_upstream_dns => ['<UPSTREAM_DNS_IP>'],
14+
conf_nameserver_upstream_dns => ['<UPSTREAM_DNS_IP>'],
1515

1616
# NTP Servers for OpenShift hosts to sync time
17-
ntp_servers => ['<NTP_SERVER_FQDN> iburst'],
17+
ntp_servers => ['<NTP_SERVER_FQDN> iburst'],
1818

1919
# The FQDNs of the OpenShift component hosts
20-
broker_hostname => '<BROKER_HOSTNAME>.example.com',
21-
named_hostname => '<BROKER_HOSTNAME>.example.com',
22-
datastore_hostname => '<BROKER_HOSTNAME>.example.com',
23-
activemq_hostname => '<BROKER_HOSTNAME>.example.com',
20+
broker_hostname => '<BROKER_HOSTNAME>.example.com',
21+
nameserver_hostname => '<BROKER_HOSTNAME>.example.com',
22+
datastore_hostname => '<BROKER_HOSTNAME>.example.com',
23+
msgserver_hostname => '<BROKER_HOSTNAME>.example.com',
2424

2525
# Auth OpenShift users created with htpasswd tool in /etc/openshift/htpasswd
2626
broker_auth_plugin => 'htpasswd',

configure_origin.pp.node_example

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,26 +4,26 @@ class { 'openshift_origin' :
44

55
# BIND / named config
66
# This is the key for updating the OpenShift BIND server
7-
bind_key => '<DNSSEC_BIND_KEY>',
7+
bind_key => '<DNSSEC_BIND_KEY>',
88
# This is the IP address for OpenShift BIND server - here, the broker.
9-
named_ip_addr => '<BROKER_IP_ADDRESS>',
9+
nameserver_ip_addr => '<BROKER_IP_ADDRESS>',
1010
# The domain under which applications should be created.
11-
domain => 'example.com',
11+
domain => 'example.com',
1212
# Apps would be named <app>-<namespace>.example.com
1313
# This also creates hostnames for local components under our domain
14-
register_host_with_named => true,
14+
register_host_with_nameserver => true,
1515

1616
# The FQDNs of the OpenShift component hosts we will need
17-
broker_hostname => '<BROKER_HOSTNAME>.example.com',
18-
activemq_hostname => '<BROKER_HOSTNAME>.example.com',
19-
node_hostname => '<NODE_HOSTNAME>.example.com',
17+
broker_hostname => '<BROKER_HOSTNAME>.example.com',
18+
msgserver_hostname => '<BROKER_HOSTNAME>.example.com',
19+
node_hostname => '<NODE_HOSTNAME>.example.com',
2020

2121
# NTP Servers for OpenShift hosts to sync time
22-
ntp_servers => ['<NTP_SERVER_FQDN> iburst'],
22+
ntp_servers => ['<NTP_SERVER_FQDN> iburst'],
2323

2424
# To enable installing the Jenkins cartridge:
25-
install_method => 'yum',
26-
jenkins_repo_base => 'http://pkg.jenkins-ci.org/redhat',
25+
install_method => 'yum',
26+
jenkins_repo_base => 'http://pkg.jenkins-ci.org/redhat',
2727

2828
# Cartridges to install on Node hosts
2929
install_cartridges => ['php', 'mysql'],

manifests/avahi.pp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
class openshift_origin::avahi {
1717
include openshift_origin::params
1818

19+
# TODO: Farm work out to Avahi module
20+
1921
package { ['avahi-cname-manager']:
2022
ensure => present,
2123
require => Class['openshift_origin::install_method'],

0 commit comments

Comments
 (0)