1 # == Class: opendaylight
3 # OpenDaylight SDN Controller
7 # Features that should normally be installed by default, but can be overridden.
9 # List of features to install in addition to the default ones.
11 # Port for ODL northbound REST interface to listen on.
13 # How to install OpenDaylight. Current options are "rpm" and "tarball", default is RPM.
15 # If installing from a tarball, use this one. Defaults to latest ODL.
17 # OpenDaylight .service file to use for tarball installs. Defaults to one used by ODL RPM.
20 $default_features = $::opendaylight::params::default_features,
21 $extra_features = $::opendaylight::params::extra_features,
22 $install_method = $::opendaylight::params::install_method,
23 $tarball_url = $::opendaylight::params::tarball_url,
24 $unitfile_url = $::opendaylight::params::unitfile_url,
25 $odl_rest_port = $::opendaylight::params::odl_rest_port,
26 ) inherits ::opendaylight::params {
31 warning('Debian family is valid but only installable with tarball method')
35 fail("Unsupported OS family: ${::osfamily}")
40 case $::operatingsystem {
42 if $::operatingsystemmajrelease != 7 {
43 # RHEL/CentOS versions < 7 not supported as they lack systemd
44 fail("Unsupported OS: ${::operatingsystem} ${::operatingsystemmajrelease}")
48 # Fedora distros < 20 are EOL as of Jan 6th 2015
49 if ! ($::operatingsystemmajrelease in [20, 21]) {
50 fail("Unsupported OS: ${::operatingsystem} ${::operatingsystemmajrelease}")
54 if $::operatingsystemmajrelease != '14.04' {
55 # Only tested on 14.04
56 fail("Unsupported OS: ${::operatingsystem} ${::operatingsystemmajrelease}")
60 fail("Unsupported OS: ${::operatingsystem}")
63 # Build full list of features to install
64 $features = union($default_features, $extra_features)
66 class { '::opendaylight::install': } ->
67 class { '::opendaylight::config': odl_rest_port => $odl_rest_port} ~>
68 class { '::opendaylight::service': } ->
69 Class['::opendaylight']