readonly PJ_OPENFLOWJAVA=3
readonly PJ_OPENFLOWPLUGIN=4
readonly PJ_DEPENDENCIES=5
-readonly PJ_DISTRIBUTION=6
+readonly PJ_OPENDAYLIGHT=6
readonly PJ_OPENDOVE=7
readonly PJ_LISPFLOWMAPPING=8
readonly PJ_LAST=8
-projects[$PJ_INTEGRATION]="integration"
-projects[$PJ_CONTROLLER]="controller"
-projects[$PJ_OVSDB]="ovsdb"
-projects[$PJ_OPENFLOWJAVA]="openflowjava"
-projects[$PJ_OPENFLOWPLUGIN]="openflowplugin"
-projects[$PJ_DEPENDENCIES]="controller-dependencies"
-projects[$PJ_DISTRIBUTION]="distribution"
-projects[$PJ_OPENDOVE]="opendove"
-projects[$PJ_LISPFLOWMAPPING]="lispflowmapping"
+projects[$PJ_INTEGRATION]="opendaylight-integration"
+projects[$PJ_CONTROLLER]="opendaylight-controller"
+projects[$PJ_OVSDB]="opendaylight-ovsdb"
+projects[$PJ_OPENFLOWJAVA]="opendaylight-openflowjava"
+projects[$PJ_OPENFLOWPLUGIN]="opendaylight-openflowplugin"
+projects[$PJ_DEPENDENCIES]="opendaylight-controller-dependencies"
+projects[$PJ_OPENDAYLIGHT]="opendaylight"
+projects[$PJ_OPENDOVE]="opendaylight-opendove"
+projects[$PJ_LISPFLOWMAPPING]="opendaylight-lispflowmapping"
versions[$PJ_INTEGRATION]=""
versions[$PJ_CONTROLLER]=""
versions[$PJ_OPENFLOWJAVA]=""
versions[$PJ_OPENFLOWPLUGIN]=""
versions[$PJ_DEPENDENCIES]=""
-versions[$PJ_DISTRIBUTION]=""
+versions[$PJ_OPENDAYLIGHT]=""
versions[$PJ_OPENDOVE]=""
versions[$PJ_LISPFLOWMAPPING]=""
suffix[$PJ_OPENFLOWJAVA]=""
suffix[$PJ_OPENFLOWPLUGIN]=""
suffix[$PJ_DEPENDENCIES]=""
-suffix[$PJ_DISTRIBUTION]=""
+suffix[$PJ_OPENDAYLIGHT]=""
suffix[$PJ_OPENDOVE]=""
suffix[$PJ_LISPFLOWMAPPING]=""
function clone_source {
for i in $gitprojects; do
# We only care about a shallow clone (no need to grab the entire project)
- log $LOGINFO "Cloning ${projects[$i]} to $buildroot/${projects[$i]}"
- git clone --depth 0 https://git.opendaylight.org/gerrit/p/${projects[$i]}.git $buildroot/${projects[$i]}
+ project=${projects[$i]:13}
+ log $LOGINFO "Cloning $project to $buildroot/${projects[$i]}"
+ git clone --depth 0 https://git.opendaylight.org/gerrit/p/$project.git $buildroot/${projects[$i]}
done
}
# - copy the archives to the SOURCES dir
# shague: need another archive method for snapshot getsource builds since
# the source did not come from a git repo.
+# versionmajor=0.1.0.snap.20140201.191633.git.7c5788d
+# versionsnapsuffix=snap.20140201.191633.git.7c5788d
+
function mk_git_archives {
local timesuffix=$1
for i in $gitprojects; do
if [ "$version" == "" ]; then
- cd $buildroot/${projects[$i]}
- suffix[$i]="snap.$timesuffix.git.$(git log -1 --pretty=format:%h)"
+ if [ "$buildtype" == "snapshot" ]; then
+ cd $buildroot/${projects[$i]}
+ suffix[$i]="snap.$timesuffix.git.$(git log -1 --pretty=format:%h)"
+ else
+ suffix[$i]=""
+ fi
else
- suffix[$i]="snap.$version"
+ if [ "$buildtype" == "snapshot" ]; then
+ suffix[$i]="snap.$version"
+ else
+ suffix[$i]=""
+ fi
fi
- cd $buildroot/integration/packaging/rpm
+ cd $buildroot/${projects[$PJ_INTEGRATION]}/packaging/rpm
+ # Get the version from the spec and append the suffix.
# integration uses the controller.spec because there isn't an integration.spec to query.
if [ ${projects[$i]} == ${projects[$PJ_INTEGRATION]} ]; then
- versions[$i]="$( rpm -q --queryformat="%{version}\n" --specfile opendaylight-${projects[$PJ_CONTROLLER]}.spec | head -n 1 | awk '{print $1}').${suffix[$i]}"
+ versions[$i]="$( rpm -q --queryformat="%{version}\n" --specfile ${projects[$PJ_CONTROLLER]}.spec | head -n 1 | awk '{print $1}').${suffix[$i]}"
else
- versions[$i]="$( rpm -q --queryformat="%{version}\n" --specfile opendaylight-${projects[$i]}.spec | head -n 1 | awk '{print $1}').${suffix[$i]}"
+ versions[$i]="$( rpm -q --queryformat="%{version}\n" --specfile ${projects[$i]}.spec | head -n 1 | awk '{print $1}').${suffix[$i]}"
+ fi
+
+ # User really wants to set the version.
+ if [ "$buildtype" == "release" ] && [ "$version" != "" ]; then
+ versions[$i]=$version
fi
- log $LOGINFO "Building archive: $tmpbuild/opendaylight-${projects[$i]}-${versions[$i]}.tar.xz"
+ log $LOGINFO "Building archive: $tmpbuild/${projects[$i]}-${versions[$i]}.tar.xz"
cd $buildroot/${projects[$i]}
- git archive --prefix=opendaylight-${projects[$i]}-${versions[$i]}/ HEAD | \
- xz > $tmpbuild/opendaylight-${projects[$i]}-${versions[$i]}.tar.xz
+ git archive --prefix=${projects[$i]}-${versions[$i]}/ HEAD | \
+ xz > $tmpbuild/${projects[$i]}-${versions[$i]}.tar.xz
done
# Use the controller versions because these projects don't have a repo.
- for i in `seq $PJ_DEPENDENCIES $PJ_DISTRIBUTION`; do
+ for i in `seq $PJ_DEPENDENCIES $PJ_OPENDAYLIGHT`; do
suffix[$i]=${suffix[$PJ_CONTROLLER]}
versions[$i]=${versions[$PJ_CONTROLLER]}
done
# Don't forget any patches.
- cp $buildroot/integration/packaging/rpm/opendaylight-integration-fix-paths.patch $tmpbuild
+ cp $buildroot/${projects[$PJ_INTEGRATION]}/packaging/rpm/opendaylight-integration-fix-paths.patch $tmpbuild
}
# Pushes rpms to the specified Nexus repository
local versionsnapsuffix="$3"
log $LOGINFO ":::::"
- log $LOGINFO "::::: building opendaylight-$project.rpm"
+ log $LOGINFO "::::: building $project.rpm"
log $LOGINFO ":::::"
- cp -f $buildroot/integration/packaging/rpm/opendaylight-$project.spec \
- $tmpbuild
+ cp -f $buildroot/${projects[$PJ_INTEGRATION]}/packaging/rpm/$project.spec $tmpbuild
cd $tmpbuild
- # Find lines starting with Version: and replace the rest of the line with the versionsnapsuffix
- sed -r -i -e '/^Version:/s/\s*$/'".$versionsnapsuffix/" opendaylight-$project.spec
+ if [ "$buildtype" == "release" ] && [ "$version" != "" ]; then
+ # Find lines starting with Version: and replace the whole line with the version requested
+ sed -r -i -e '/^Version:./c\Version: '"$versionmajor" $project.spec
+ else
+ # Find lines starting with Version: and replace the rest of the line with the versionsnapsuffix
+ sed -r -i -e '/^Version:/s/\s*$/'".$versionsnapsuffix/" $project.spec
+ fi
# Set the write values in the spec files.
case "$project" in
# Set the version for the integration source.
# Find lines with opendaylight-integration-%{version} and replace %{version} with the version.
sed -r -i -e '/opendaylight-integration-\%\{version\}/s/\%\{version\}/'"${versions[$PJ_INTEGRATION]}"'/g' \
- opendaylight-$project.spec
+ $project.spec
;;
${projects[$PJ_DEPENDENCIES]})
# Set the version for ovsdb in the dependencies spec.
# Find lines with opendaylight-ovsdb-%{version} and replace %{version} with the version.
sed -r -i -e '/opendaylight-ovsdb-\%\{version\}/s/\%\{version\}/'"${versions[$PJ_OVSDB]}"'/g' \
- opendaylight-$project.spec
+ $project.spec
# Find lines with opendaylight-ovsdb-dependencies-%{version} and replace %{version} with the version.
sed -r -i -e '/opendaylight-ovsdb-dependencies-\%\{version\}/s/\%\{version\}/'"${versions[$PJ_OVSDB]}"'/g' \
- opendaylight-$project.spec
+ $project.spec
;;
*)
# Rewrite the mvn command in the rpmbuild if the user requests it.
if [ "$mockmvn" != "" ]; then
- # Find lines starting with export MAVEN_OPTS= and repalce the whole line with $mockmvn
- sed -r -i -e '/^export MAVEN_OPTS=./c\ '"$mockmvn" opendaylight-$project.spec
+ # Find lines starting with export MAVEN_OPTS= and replace the whole line with $mockmvn
+ sed -r -i -e '/^export MAVEN_OPTS=./c\ '"$mockmvn" $project.spec
fi
# Build the source RPM for use by mock later.
#rm -f SRPMS/*.src.rpm
- log $LOGINFO "::::: building opendaylight-$project.src.rpm in rpmbuild"
+ log $LOGINFO "::::: building $project.src.rpm with rpmbuild"
rpmbuild -bs --define '%_topdir '"`pwd`" --define '%_sourcedir %{_topdir}' \
- --define "%dist .$pkg_dist_suffix" opendaylight-$project.spec
+ --define "%dist .$pkg_dist_suffix" $project.spec
rc=$?
if [ $rc != 0 ]; then
exit $RCRPMBUILDERROR
fi
- log $LOGINFO "::::: building opendaylight-$project.rpm in mock"
+ log $LOGINFO "::::: building $project.rpm with mock"
- resultdir="repo/$project.$pkg_dist_suffix.noarch.snap"
+ if [ "$buildtype" == "release" ]; then
+ resultdir="repo/$project.$pkg_dist_suffix.noarch"
+ else
+ resultdir="repo/$project.$pkg_dist_suffix.noarch.snap"
+ fi
# Build the rpm using mock.
# Keep the build because we will need the distribution zip file for later
# when building the controller-dependencies.rpm.
eval $mock_cmd $mockdebug -r $dist --no-clean --no-cleanup-after --resultdir \"$resultdir\" \
-D \"dist .$pkg_dist_suffix\" -D \"noclean 1\" \
- SRPMS/opendaylight-$project-$versionmajor-*.src.rpm
+ SRPMS/$project-$versionmajor-*.src.rpm
rc=$?
if [ $rc != 0 ]; then
exit $RCRMOCKERROR
fi
+ log $LOGINFO "::::: finished building $project.rpm in mock"
+
# Copy the distribution zip from the controller and ovsdb projects
# for use in the dependencies.rpm.
case "$project" in
- controller)
+ ${projects[$PJ_CONTROLLER]})
log $LOGINFO "::::: Copying $project distribution.zip."
eval $mock_cmd $mockdebug -r $dist --no-clean --no-cleanup-after --resultdir \"$resultdir\" \
-D \"dist .$pkg_dist_suffix\" -D \"noclean 1\" \
- --copyout \"builddir/build/BUILD/opendaylight-$project-$versionmajor/opendaylight/distribution/opendaylight/target/distribution.opendaylight-osgipackage.zip\" \"$resultdir/opendaylight-$project-$versionmajor.zip\"
+ --copyout \"builddir/build/BUILD/$project-$versionmajor/opendaylight/distribution/opendaylight/target/distribution.opendaylight-osgipackage.zip\" \"$resultdir/$project-$versionmajor.zip\"
rc1=$?
- ln -sf $resultdir/opendaylight-$project-$versionmajor.zip $tmpbuild
+ ln -sf $resultdir/$project-$versionmajor.zip $tmpbuild
rc2=$?
- if [ ! -e $tmpbuild/opendaylight-$project-$versionmajor.zip ]; then
+ if [ ! -e $tmpbuild/$project-$versionmajor.zip ]; then
log $LOGERROR "cannot find $project distribution zip file (rc=$rc1:$rc2)."
exit $RCERROR
fi
;;
- ovsdb)
+ ${projects[$PJ_OVSDB]})
log $LOGINFO "::::: Copying $project distribution.zip."
# Grab the version from the pom.xml file.
# Get the lines between the parent tags, then get the line with the version tag and remove leading space and
# the tag itself, then remove the trailing tag to be left with the version.
- pomversion=`sed -n -e '/<parent>/,/<\/parent>/p' "$buildroot"/ovsdb/pom.xml | sed -n -e '/<version>/s/.*<version>//p' | sed -n -e 's/<\/version>//p'`
+ pomversion=`sed -n -e '/<parent>/,/<\/parent>/p' "$buildroot/${projects[$PJ_OVSDB]}/pom.xml" | sed -n -e '/<version>/s/.*<version>//p' | sed -n -e 's/<\/version>//p'`
eval $mock_cmd $mockdebug -r $dist --no-clean --no-cleanup-after --resultdir \"$resultdir\" \
-D \"dist .$pkg_dist_suffix\" -D \"noclean 1\" \
- --copyout \"builddir/build/BUILD/opendaylight-$project-$versionmajor/distribution/opendaylight/target/distribution.$project-$pomversion-osgipackage.zip\" \"$resultdir/opendaylight-$project-$versionmajor.zip\"
+ --copyout \"builddir/build/BUILD/$project-$versionmajor/distribution/opendaylight/target/distribution.ovsdb-$pomversion-osgipackage.zip\" \"$resultdir/$project-$versionmajor.zip\"
rc1=$?
- ln -sf $resultdir/opendaylight-$project-$versionmajor.zip $tmpbuild
+ ln -sf $resultdir/$project-$versionmajor.zip $tmpbuild
rc2=$?
- if [ ! -e $tmpbuild/opendaylight-ovsdb-$versionmajor.zip ]; then
+ if [ ! -e $tmpbuild/$project-$versionmajor.zip ]; then
log $LOGERROR "cannot find $project distribution zip file (rc=$rc1:$rc2)."
exit $RCERROR
fi
buildroot)
cd $buildroot
- for i in `seq $PJ_INTEGRATION $PJ_OPENFLOWPLUGIN`; do
- if [ ! -d ${projects[$i]} ]; then
+
+ # Check if all the projects dirs are really there.
+ for i in $gitprojects; do
+ if [ ! -d ${projects[$i]}; then
log $LOGERROR "Missing ${projects[$i]}"
exit $RCPARMSERROR
fi
log $LOGINFO "Building a snapshot build"
build_snapshot
else
- log $LOGINFO "Release builds are not supported yet."
- build_release
+ #log $LOGINFO "Release builds are not supported yet."
+ #build_release
+ log $LOGINFO "Building a release build"
+ build_snapshot
fi
date_end=$(date +%s)
BuildRequires: java-devel
BuildRequires: maven
+Requires: java >= 1:1.7.0
%if 0%{?fedora}
BuildRequires: systemd
%else
BuildRequires: sysvinit-tools
%endif
-Requires: java >= 1:1.7.0
# todo: Need to create proper packages for all the dependencies.
# Here you should have at least dependencies for the packages containing .jar
# dependencies package.
#Requires: slf4j
-Requires: %{name}-dependencies
-Requires: opendaylight-openflowjava
-Requires: opendaylight-openflowplugin
+#Requires: %{name}-dependencies
+#Requires: opendaylight-openflowjava
+#Requires: opendaylight-openflowplugin
%if 0%{?fedora}
Requires(post): systemd
mkdir -p %{buildroot}%{data_dir}/configuration
mv tmp/opendaylight/configuration/config.ini %{buildroot}%{configuration_dir}
+sed -i -e 's/#\ ovsdb.of.version=1.3/ovsdb.of.version=1.3/' %{buildroot}%{configuration_dir}/config.ini
ln -s %{configuration_dir}/config.ini %{buildroot}%{data_dir}/configuration
mv tmp/opendaylight/configuration/* %{buildroot}%{resources_dir}/configuration
rmdir tmp/opendaylight/configuration
rm %{buildroot}%{resources_dir}/run.sh
install -m 755 -D opendaylight-integration-%{version}/distributions/virtualization/src/assemble/resources/run.sh \
%{buildroot}%{resources_dir}/run.sh
-install -m 755 -D opendaylight-integration-%{version}/packaging/rpm/run.dist.sh %{buildroot}%{resources_dir}/run.dist.sh
+install -m 755 -D opendaylight-integration-%{version}/packaging/rpm/run.odl.sh %{buildroot}%{resources_dir}/run.odl.sh
# Usually one wants to replace the .jar files of the dependencies by symlinks
# to the ones provided to the system. This assumes the dependencies have been
chmod 755 %{buildroot}%{resources_dir}/run.sh
chmod 755 %{buildroot}%{resources_dir}/run.base.sh
chmod 755 %{buildroot}%{resources_dir}/run.internal.sh
-chmod 755 %{buildroot}%{resources_dir}/run.dist.sh
+chmod 755 %{buildroot}%{resources_dir}/run.odl.sh
%if 0%{?rhel}
chmod 755 %{buildroot}%{_initddir}/%{name}
%endif
%endif
%changelog
+* Sat Feb 01 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.4.0
+- Changed package name to opendaylight.
+- Removed openflowjava and openflowplugin Requires.
+
+* Wed Jan 22 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.9.0
+- Updates to support editions.
+
* Wed Jan 22 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.8.0
- Fix changelog day error.
--- /dev/null
+# Spec file only supports RHEL and Fedora now
+%if 0%{?rhel} || 0%{?fedora}
+
+Name: opendaylight
+Version: 0.1.0
+Release: 0.4.0%{?dist}
+Summary: OpenDaylight SDN Controller Platform
+Group: Applications/Communications
+License: EPL
+URL: http://www.opendaylight.org
+BuildArch: noarch
+
+Requires: opendaylight-controller
+Requires: opendaylight-controller-dependencies
+Requires: opendaylight-openflowjava
+Requires: opendaylight-openflowplugin
+Requires: opendaylight-ovsdb
+
+%description
+The OpenDaylight SDN Controller Platform provides the core
+services and abstractions needed for building an SDN controller.
+
+The Base edition of OpenDaylight is designed for testing and experimental
+purposes.
+
+%package virtualization
+Summary: OpenDaylight SDN Controller Platform Virtualization Edition
+Group: Applications/Communications
+Requires: %{name}
+#Requires: opendaylight-affinity
+#Requires: opendaylight-defense4all
+#Requires: opendaylight-opendove
+Requires: opendaylight-opendove-odmc
+#Requires: opendaylight-vtn
+
+%description virtualization
+The Virtualization edition of OpenDaylight is geared towards data centers.
+It includes the OVSDB protocol southbound and the Affinity Service, VTN,
+DOVE, and the OpenStack Service.
+
+%package serviceprovider
+Summary: OpenDaylight SDN Controller Platform Virtualization Edition
+Group: Applications/Communications
+Requires: %{name}
+#Requires: opendaylight-affinity
+#Requires: opendaylight-bgpcep
+#Requires: opendaylight-defense4all
+Requires: opendaylight-lispflowmapping
+#Requires: opendaylight-snmp4sdn
+
+%description serviceprovider
+The Service Provider edition of OpenDaylight is designed for network operator
+use. It does not include OVSDB, VTN or DOVE, but does include SNMP, BGP-LS,
+PCEP, and LISP southbound and the Affinity Service and the LISP Service northbound.
+
+%files
+
+%files virtualization
+
+%files serviceprovider
+
+%endif
+
+%changelog
+* Sat Feb 01 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.4.0
+- Changed package name to opendaylight.
+- Added edition sub packages.
+
+* Sat Jan 18 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.3.0
+- Removed controller-dependencies from Requires because controller already pulls it in.
+
+* Thu Jan 09 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.2.0
+- Updates for OF1.3 support.
+- Remove java Requires.
+
+* Thu Jan 02 2014 Sam Hague <shague@redhat.com> - 0.1.0-0.1.0
+- Initial package.
--- /dev/null
+#!/bin/bash
+
+usage() {
+ echo -e "Usage:\t$0 base|virt-ovsdb|virt-vtn|virt-opendove|virt-affinity|sp|-stop|-status|help\n"
+
+ echo -e "\tbase: base controller edition, good for simple testing"
+ echo -e "\tvirt-ovsdb: virtualization controller edition based on ovsdb"
+ echo -e "\tvirt-vtn: virtualization controller edition based on vtn (not supported yet)"
+ echo -e "\tvirt-opendove: virtualization controller edition based on opendove (not supported yet)"
+ echo -e "\tsp: service provider controller edition (not supported yet)"
+ echo -e "\t-stop: stop the controller"
+ echo -e "\t-status: check if controller is currently running"
+ echo -e "\thelp: generate this help text"
+}
+
+option=$1;
+shift
+
+case "$option" in
+base)
+ filter="affinity|bgpcep|lispflowmapping|opendove|ovsdb.ovsdb.neutron|snmp4sdn|vtn|\
+yangtools.model.(ietf-ted-2013|ietf-topology-isis-2013|ietf-topology-l3-2013|\
+ietf-topology-l3-unicast-igp-2013|ietf-topology-ospf-2013)"
+
+ bundlefilter="-bundlefilter org.opendaylight.(${filter})"
+ exec /usr/share/opendaylight-controller/run.base.sh $bundlefilter "$@"
+ ;;
+
+virt-ovsdb)
+ filter="opendove|vtn|\
+bgpcep|lispflowmapping|snmp4sdn|\
+yangtools.model.(ietf-ted-2013|ietf-topology-isis-2013|ietf-topology-l3-2013|\
+ietf-topology-l3-unicast-igp-2013|ietf-topology-ospf-2013)"
+
+ bundlefilter="-bundlefilter org.opendaylight.(${filter})"
+ exec /usr/share/opendaylight-controller/run.base.sh $bundlefilter "$@"
+ ;;
+
+virt-opendove)
+ echo "$option not supported yet"
+ filter="ovsdb|vtn|\
+bgpcep|lispflowmapping|snmp4sdn|\
+yangtools.model.(ietf-ted-2013|ietf-topology-isis-2013|ietf-topology-l3-2013|\
+ietf-topology-l3-unicast-igp-2013|ietf-topology-ospf-2013)"
+
+ bundlefilter="-bundlefilter org.opendaylight.(${filter})"
+ exec /usr/share/opendaylight-controller/run.base.sh $bundlefilter "$@"
+ ;;
+
+virt-vtn)
+ echo "$option not supported yet"
+ filter="affinity|opendove|ovsdb|controller.(arphandler|samples)|\
+bgpcep|lispflowmapping|snmp4sdn|\
+yangtools.model.(ietf-ted-2013|ietf-topology-isis-2013|ietf-topology-l3-2013|\
+ietf-topology-l3-unicast-igp-2013|ietf-topology-ospf-2013)"
+
+ bundlefilter="-bundlefilter org.opendaylight.(${filter})"
+ exec /usr/share/opendaylight-controller/run.base.sh $bundlefilter "$@"
+ ;;
+
+virt-affinity)
+ echo "$option not supported yet"
+ filter="vtn|opendove|ovsdb|controller.samples|\
+bgpcep|lispflowmapping|snmp4sdn|\
+yangtools.model.(ietf-ted-2013|ietf-topology-isis-2013|ietf-topology-l3-2013|\
+ietf-topology-l3-unicast-igp-2013|ietf-topology-ospf-2013)"
+
+ bundlefilter="-bundlefilter org.opendaylight.(${filter})"
+ exec /usr/share/opendaylight-controller/run.base.sh $bundlefilter "$@"
+ ;;
+
+sp)
+ echo "$option not supported yet"
+ filter="opendove|ovsdb.ovsdb.neutron|vtn"
+
+ bundlefilter="-bundlefilter org.opendaylight.(${filter})"
+ exec /usr/share/opendaylight-controller/run.base.sh $bundlefilter "$@"
+ ;;
+
+-stop)
+ exec /usr/share/opendaylight-controller/run.internal.sh -stop
+ ;;
+
+-status)
+ exec /usr/share/opendaylight-controller/run.internal.sh -status
+ ;;
+
+help)
+ usage
+ exit 0
+ ;;
+*)
+ echo "Invalid option: $option"
+ usage
+ ;;
+esac
+
+exit -1