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

Commit 4e69adb

Browse files
committed
Remove Fedora related code
Fedora is no longer supported by Origin and was obviously never supported by OSE so lets excise the Fedora specific code paths to simplify our code base.
1 parent bead518 commit 4e69adb

20 files changed

+74
-326
lines changed

README.asciidoc

+2-7
Original file line numberDiff line numberDiff line change
@@ -170,13 +170,13 @@ override_install_repo path for OpenShift RPMs. Used when doing local builds.
170170
Default: none
171171

172172
=== os_repo
173-
The URL for a Fedora 19/RHEL 6 yum repository used with the "yum" install method.
173+
The URL for a RHEL/Centos 6 yum repository used with the "yum" install method.
174174
Should end in x86_64/os/.
175175

176176
Default: no change
177177

178178
=== os_updates_repo
179-
The URL for a Fedora 19/RHEL 6 yum updates repository used with the "yum" install method.
179+
The URL for a RHEL/Centos 6 yum updates repository used with the "yum" install method.
180180
Should end in x86_64/.
181181

182182
Default: no change
@@ -781,10 +781,6 @@ Set development mode and extra logging.
781781

782782
Default: false
783783

784-
=== install_login_shell
785-
Install a Getty shell which displays DNS, IP and login information. Used for
786-
all-in-one VM installation.
787-
788784
=== register_host_with_nameserver
789785
Setup DNS entries for this host in a locally installed bind DNS instance.
790786

@@ -856,7 +852,6 @@ List of cartridges to be installed on the node. Options:
856852
* ruby
857853
* jenkins
858854
* jenkins-client
859-
* mariadb for Fedora Deployments
860855
* mysql for CentOS / RHEL deployments
861856
* jbosseap requires OpenShift Enterprise JBoss EAP add-on
862857
* jbossas not available in OpenShift Enterprise

configure_origin.pp.mongo_replset.example

+1-8
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,6 @@
55
unless => "/bin/hostname | /bin/grep ${my_hostname}",
66
}
77

8-
if $::operatingsystem == 'Fedora' {
9-
exec { "set_etc_hostname":
10-
command => "/bin/echo ${my_hostname} > /etc/hostname",
11-
unless => "/bin/grep ${my_hostname} /etc/hostname",
12-
}
13-
}
14-
158
if $::operatingsystem == 'CentOS' {
169
exec { "set_etc_hostname":
1710
command => "/bin/sed -ri \'s/HOSTNAME=.*/HOSTNAME=${my_hostname}/\' /etc/sysconfig/network",
@@ -30,7 +23,7 @@ class { 'openshift_origin' :
3023
datastore1_ip_addr => '<MEMBER1_IP>',
3124
datastore2_ip_addr => '<MEMBER2_IP>',
3225
datastore3_ip_addr => '<MEMBER3_IP>',
33-
26+
3427
# Components to install on this host:
3528
roles => ['broker','nameserver','msgserver','datastore'],
3629
# BIND / nameserver config

manifests/broker.pp

+3-12
Original file line numberDiff line numberDiff line change
@@ -234,13 +234,9 @@
234234
}
235235
}
236236

237-
# SCL and Puppet don't play well together; the 'default' here
238-
# circumvents the use of the `scl enable ruby193` mechanism
239-
# while still invoking ruby commands in the correct context
240-
$broker_bundle_show = $::operatingsystem ? {
241-
'Fedora' => '/usr/bin/bundle show',
242-
default => 'LD_LIBRARY_PATH=/opt/rh/ruby193/root/usr/lib64 GEM_PATH=/opt/rh/ruby193/root/usr/local/share/gems:/opt/rh/ruby193/root/usr/share/gems /opt/rh/ruby193/root/usr/bin/bundle show',
243-
}
237+
# SCL and Puppet don't play well together; circumvents the use of the `scl enable ruby193` mechanism while
238+
# still invoking ruby commands in the correct context
239+
$broker_bundle_show = 'LD_LIBRARY_PATH=/opt/rh/ruby193/root/usr/lib64 GEM_PATH=/opt/rh/ruby193/root/usr/local/share/gems:/opt/rh/ruby193/root/usr/share/gems /opt/rh/ruby193/root/usr/bin/bundle show'
244240

245241
exec { 'Broker gem dependencies':
246242
cwd => '/var/www/openshift/broker/',
@@ -281,9 +277,4 @@
281277
onlyif => '/bin/grep \'VirtualHost _default\' /etc/httpd/conf.d/ssl.conf',
282278
require => Package['openshift-origin-broker'],
283279
}
284-
if $::openshift_origin::install_login_shell {
285-
anchor { 'openshift_origin::broker_login_shell': } ->
286-
class { 'openshift_origin::login_shell': } ->
287-
anchor { 'openshift_origin::broker_login_shell': }
288-
}
289280
}

manifests/console.pp

+2-9
Original file line numberDiff line numberDiff line change
@@ -122,15 +122,8 @@
122122
# SCL and Puppet don't play well together; the 'default' here
123123
# circumvents the use of the `scl enable ruby193` mechanism
124124
# while still invoking ruby commands in the correct context
125-
$console_asset_rake_cmd = $::operatingsystem ? {
126-
'Fedora' => '/usr/bin/rake assets:precompile',
127-
default => 'LD_LIBRARY_PATH=/opt/rh/ruby193/root/usr/lib64:/opt/rh/v8314/root/usr/lib64 GEM_PATH=/opt/rh/ruby193/root/usr/local/share/gems:/opt/rh/ruby193/root/usr/share/gems /opt/rh/ruby193/root/usr/bin/rake assets:precompile',
128-
}
129-
130-
$console_bundle_show = $::operatingsystem ? {
131-
'Fedora' => '/usr/bin/bundle show',
132-
default => 'LD_LIBRARY_PATH=/opt/rh/ruby193/root/usr/lib64 GEM_PATH=/opt/rh/ruby193/root/usr/local/share/gems:/opt/rh/ruby193/root/usr/share/gems /opt/rh/ruby193/root/usr/bin/bundle show',
133-
}
125+
$console_asset_rake_cmd = 'LD_LIBRARY_PATH=/opt/rh/ruby193/root/usr/lib64:/opt/rh/v8314/root/usr/lib64 GEM_PATH=/opt/rh/ruby193/root/usr/local/share/gems:/opt/rh/ruby193/root/usr/share/gems /opt/rh/ruby193/root/usr/bin/rake assets:precompile'
126+
$console_bundle_show = 'LD_LIBRARY_PATH=/opt/rh/ruby193/root/usr/lib64 GEM_PATH=/opt/rh/ruby193/root/usr/local/share/gems:/opt/rh/ruby193/root/usr/share/gems /opt/rh/ruby193/root/usr/bin/bundle show'
134127

135128
exec { 'Console gem dependencies':
136129
cwd => '/var/www/openshift/console/',

manifests/datastore.pp

+8-39
Original file line numberDiff line numberDiff line change
@@ -41,45 +41,14 @@
4141
],
4242
}
4343

44-
if $openshift_origin::configure_mongodb == 'delayed' {
45-
$openshift_init_provider = $::operatingsystem ? {
46-
'Fedora' => 'systemd',
47-
'CentOS' => 'redhat',
48-
default => 'redhat',
49-
}
50-
51-
if $openshift_init_provider == 'systemd' {
52-
file { 'mongo setup service':
53-
ensure => present,
54-
path => '/usr/lib/systemd/system/openshift-mongo-setup.service',
55-
content => template('openshift_origin/mongodb/openshift-mongo-setup.service'),
56-
owner => 'root',
57-
group => 'root',
58-
mode => '0644',
59-
require => File['mongo setup script'],
60-
}
61-
} else {
62-
fail 'Delayed mongo setup for RHEL not available'
63-
}
64-
65-
service { ['openshift-mongo-setup']:
66-
require => [
67-
File['mongo setup script'],
68-
File['mongo setup service'],
69-
],
70-
provider => $openshift_init_provider,
71-
enable => true,
72-
}
73-
} else {
74-
exec { '/usr/sbin/oo-mongo-setup':
75-
command => '/usr/sbin/oo-mongo-setup',
76-
timeout => 1800,
77-
require => [
78-
File['mongo setup script'],
79-
Class['openshift_origin::update_conf_files'],
80-
],
81-
creates => '/etc/openshift/.mongo-setup-complete',
82-
}
44+
exec { '/usr/sbin/oo-mongo-setup':
45+
command => '/usr/sbin/oo-mongo-setup',
46+
timeout => 1800,
47+
require => [
48+
File['mongo setup script'],
49+
Class['openshift_origin::update_conf_files'],
50+
],
51+
creates => '/etc/openshift/.mongo-setup-complete',
8352
}
8453

8554
if $openshift_origin::mongodb_replicasets {

manifests/init.pp

+7-20
Original file line numberDiff line numberDiff line change
@@ -69,35 +69,27 @@
6969
#
7070
# [*repos_base*]
7171
# Base path to repository for OpenShift Origin
72-
# Nightlies:
73-
# Fedora: https://mirror.openshift.com/pub/origin-server/nightly/fedora-19
74-
# RHEL: https://mirror.openshift.com/pub/origin-server/nightly/rhel-6
75-
# Release-2:
76-
# Fedora: https://mirror.openshift.com/pub/origin-server/release/2/fedora-19
77-
# RHEL: https://mirror.openshift.com/pub/origin-server/release/2/rhel-6
78-
# Default: Fedora-19 Nightlies
72+
#
73+
# Default: https://mirror.openshift.com/pub/origin-server/nightly/rhel-6
7974
#
8075
# [*architecture*]
8176
# CPU Architecture to use for the definition OpenShift Origin yum repositories
82-
# Defaults to $::architecture
83-
# Fedora:
84-
# x86_64
85-
# armv7hl
86-
# RHEL:
87-
# x86_64
77+
#
78+
# Default: $::architecture (from facter)
79+
# NOTE: Currently only the `x86_64` architecutre is supported and this parameter has no effect.
8880
#
8981
# [*override_install_repo*]
9082
# Repository path override. Uses dependencies from repos_base but uses
9183
# override_install_repo path for OpenShift RPMs. Used when doing local builds.
9284
# Default: none
9385
#
9486
# [*os_repo*]
95-
# The URL for a Fedora 19/RHEL 6 yum repository used with the "yum" install method.
87+
# The URL for a RHEL/Centos 6 yum repository used with the "yum" install method.
9688
# Should end in x86_64/os/.
9789
# Default: no change
9890
#
9991
# [*os_updates*]
100-
# The URL for a Fedora 19/RHEL 6 yum updates repository used with the "yum" install method.
92+
# The URL for a RHEL/Centos 6 yum updates repository used with the "yum" install method.
10193
# Should end in x86_64/.
10294
# Default: no change
10395
#
@@ -593,10 +585,6 @@
593585
# Set development mode and extra logging.
594586
# Default: false
595587
#
596-
# [*install_login_shell*]
597-
# Install a Getty shell which displays DNS, IP and login information. Used for
598-
# all-in-one VM installation.
599-
#
600588
# [*register_host_with_nameserver*]
601589
# Setup DNS entries for this host in a locally installed bind DNS instance.
602590
# Default: false
@@ -668,7 +656,6 @@
668656
# * ruby
669657
# * jenkins
670658
# * jenkins-client
671-
# * mariadb for Fedora deployments
672659
# * mysql for CentOS / RHEL deployments
673660
# * jbossas not available in OpenShift Enterprise
674661
# * jbosseap requires OpenShift Enterprise JBoss EAP add-on

manifests/login_shell.pp

-50
This file was deleted.

manifests/mcollective_server.pp

+1-22
Original file line numberDiff line numberDiff line change
@@ -49,33 +49,12 @@
4949
notify => Service["${::openshift_origin::params::ruby_scl_prefix}mcollective"],
5050
}
5151

52-
if( $::operatingsystem == 'Fedora' ) {
53-
exec { 'systemd-daemon-reload':
54-
command => '/usr/bin/systemctl daemon-reload',
55-
refreshonly => true,
56-
}
57-
58-
$require_real = [
59-
File['mcollective server config', '/usr/lib/systemd/system/mcollective.service'],
60-
Exec['systemd-daemon-reload']
61-
]
62-
63-
file { '/usr/lib/systemd/system/mcollective.service':
64-
content => template('openshift_origin/mcollective/mcollective.service'),
65-
require => Package['mcollective'],
66-
notify => Service["${::openshift_origin::params::ruby_scl_prefix}mcollective"]
67-
}
68-
} else {
69-
$require_real = File['mcollective server config']
70-
}
71-
7252
service { "${::openshift_origin::params::ruby_scl_prefix}mcollective":
7353
ensure => true,
7454
enable => true,
7555
hasstatus => true,
7656
hasrestart => true,
77-
require => $require_real,
78-
provider => $::openshift_origin::params::os_init_provider,
57+
require => File['mcollective server config'],
7958
}
8059

8160
exec { 'openshift-facts':

0 commit comments

Comments
 (0)