55637faa6f
Experimental support for FreeBSD. Requires a fairly recent version of FreeBSD with pkgng installed. The ovs commands remain exactly the same, however it is necessary to replace invocations of the ip command with and equivalent ifconfig command in FreeBSD. Also, appropriate setting of the datapath is also required to make a bridge actually appear as an interface. Specified the default expected parameters for vswitch::ovs when used under FreeBSD. Also, some minor changes were made to the vswitch::ovs parameters, most notably the addition of a status parameter for the required services (ovs-vswitchd,ovsdb-server). Change-Id: I4c3923d17ac04402ac94ccea01e1d8ffcb5c0e4f
31 lines
980 B
Puppet
31 lines
980 B
Puppet
# vswitch params
|
|
#
|
|
class vswitch::params {
|
|
case $::osfamily {
|
|
'Redhat': {
|
|
$ovs_package_name = 'openvswitch'
|
|
$ovs_dkms_package_name = undef
|
|
$ovs_service_name = 'openvswitch'
|
|
$provider = 'ovs_redhat'
|
|
}
|
|
'Debian': {
|
|
$ovs_package_name = 'openvswitch-switch'
|
|
$ovs_dkms_package_name = 'openvswitch-datapath-dkms'
|
|
$ovs_service_name = 'openvswitch-switch'
|
|
$provider = 'ovs'
|
|
}
|
|
'FreeBSD': {
|
|
$ovs_package_name = 'openvswitch'
|
|
$ovs_pkg_provider = 'pkgng'
|
|
$provider = 'ovs'
|
|
$ovs_service_name = 'ovs-vswitchd'
|
|
$ovsdb_service_name = 'ovsdb-server'
|
|
$ovs_status = "/usr/sbin/service ${ovs_service_name} onestatus"
|
|
$ovsdb_status = "/usr/sbin/service ${ovsdb_service_name} onestatus"
|
|
}
|
|
default: {
|
|
fail " Osfamily ${::osfamily} not supported yet"
|
|
}
|
|
} # Case $::osfamily
|
|
}
|