Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
242 lines (214 sloc) 8.46 KB
name: openswitch
version: 0.2.0
summary: OpenSwitch NOS
description: OpenSwitch Network Operating System suite
icon: OpenSwitchLogo.png
apps:
start-openswitch:
command: usr/sbin/start-openswitch
plugs: [ networking ]
stop-openswitch:
command: usr/sbin/stop-openswitch
plugs: [ networking ]
ovs-appctl:
command: usr/bin/ovs-appctl
plugs: [ networking ]
ovsdb-tool:
command: usr/bin/ovsdb-tool
plugs: [ networking ]
ovsdb-client:
command: usr/bin/ovsdb-client
plugs: [ networking ]
plugs:
# TODO - come up with a better security profile for the daemons.
networking:
interface: old-security
security-template: unconfined
# uses github mirrors for speed instead of the canonical git.openswitch.net
# repos
parts:
# schema files required for ops-openvswitch
ops:
plugin: make
source: git://github.com/open-switch/ops
# based on upstream recipe:
# https://github.com/open-switch/ops-build/blob/master/yocto/openswitch/meta-distro-openswitch/recipes-ops/openvswitch/ops-openvswitch.bb
# without the patches though and without libjemalloc alternate malloc impl
# (performance improvement for ovsdb)
# also this is built with simulator provider for now to defer integration of
# BCM's OpenNSL
ops-openvswitch:
plugin: x-autotools
configflags:
- "OPS_BUILD=1"
- "OPEN_HALON_BUILD=1"
- "BUILD_OVS_VSWITCHD=0"
- "BUILD_PLUGINS_LIB=1"
- "--prefix=/usr"
- "--enable-shared"
- "--disable-static"
- "--enable-simulator-provider"
source: git://github.com/ops-snappy/ops-openvswitch
stage-packages:
- libyaml-dev
build-packages:
- pkg-config
- libjemalloc-dev
- libltdl-dev
- libssl-dev
after: [ ops, ops-cfgd, ops-restd, ops-aaa-utils-python ]
precmd: ['bash', '-c', 'cp -v ../../../stage/usr/share/openvswitch/*.{extschema,ovsschema,xml} vswitchd/']
# TODO: Figure out why build is not installing the libraries.
# In the meantime, we'll install them manually.
postcmd: ['bash', '-c', '(test -d ../install/usr/lib || mkdir -p ../install/usr/lib) && cp -a ovsdb/.libs/*.so* ../install/usr/lib && cp -a lib/.libs/*.so* ../install/usr/lib && cp -a ofproto/.libs/*.so* ../install/usr/lib && cp -a vtep/.libs/*.so* ../install/usr/lib && (test -d ../install/usr/lib/python2.7/site-packages || mkdir -p ../install/usr/lib/python2.7/site-packages) && mv ../install/usr/share/openvswitch/python/ovs ../install/usr/lib/python2.7/site-packages/']
ops-init:
plugin: make
source: src/ops-init
ops-utils:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-utils
after: [ ops-openvswitch ]
gtest:
plugin: cmake
source: https://github.com/lool/googletest.git
source-type: git
configflags:
- "-DBUILD_SHARED_LIBS=ON"
- "-DCMAKE_INSTALL_PREFIX=/usr"
i2c-header-hack:
plugin: copy
files:
/usr/include/linux/i2c-dev.h: usr/include/linux/i2c-dev-user.h
build-packages: [ libi2c-dev ]
ops-hw-config:
plugin: x-cmake
source: git://github.com/ops-snappy/ops-hw-config
after: [ gtest, i2c-header-hack ]
stage-packages:
- libyaml-cpp0.3-dev
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
postcmd: ['bash', '-c', '(test -d ../install/etc/openswitch || mkdir -p ../install/etc/openswitch) && cp -vr ../src/Generic-x86 ../install/etc/openswitch']
# TODO - There is a race condition that sometimes causes ops-cli build to fail.
# The problem is that ops-cli includes <memory.h> located at lib/memory.h.
# However, the CMake include search paths search the staged area before
# searching the local area. Occasionally, it finds the wrong memory.h and
# the build fails.
ops-cli:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-cli
after: [ ops-openvswitch, ops-utils ]
build-packages: [ libreadline-dev, libaudit-dev, pkg-config, libsystemd-dev ]
stage-packages: [ libreadline-dev ]
ops-sysd:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
- "-DPLATFORM_SIMULATION=ON"
stage-packages:
- zlib1g-dev
source: git://github.com/ops-snappy/ops-sysd
after: [ ops-openvswitch, ops-hw-config, ops-utils, ops-cli, ops-supportability ]
ops-supportability:
plugin: cmake
source: git://github.com/ops-snappy/ops-supportability
after: [ ops-cli ]
ops-supportability-python:
plugin: x-python2
source: git://github.com/ops-snappy/ops-supportability
source-subdir: src/python
after: [ ops-cli ]
postcmd: ['bash', '-c', 'install -d ../../../install/usr/lib/python2.7/site-packages && install build/lib.linux-x86_64-2.7/ops_diagdump.py ../../../install/usr/lib/python2.7/site-packages && install build/lib.linux-x86_64-2.7/ops_eventlog.py ../../../install/usr/lib/python2.7/site-packages']
ops-aaa-utils-python:
plugin: x-python2
source: git://github.com/open-switch/ops-aaa-utils
python-packages: [ pam ]
postcmd: ['bash', '-c', 'sed -i -- "s,^#!.*/python,#!/usr/bin/env python," ../install/usr/bin/*']
before: [ ops-openvswitch ]
ops-cfgd:
plugin: x-python2
source: git://github.com/open-switch/ops-cfgd
# TODO - requires 'json', but pip can't find it.
python-packages: [ argparse, distribute ]
postcmd: ['bash', '-c', 'sed -i -- "s,^#!.*/python,#!/usr/bin/env python," ../install/usr/bin/*']
before: [ ops-openvswitch ]
ops-restd:
plugin: x-python2
source: git://github.com/ops-snappy/ops-restd
build-packages: [ libffi-dev ]
python-packages: [ tornado, html, inflect, jsonschema, jsonpatch, pyOpenSSL, PAM ]
postcmd: ['bash', '-c', 'sed -i -- "s,^#!.*/python,#!/usr/bin/env python," ../install/usr/bin/*']
before: [ ops-openvswitch, ops-cfgd ]
after: [ ops ]
ops-restd-json:
plugin: x-copy
precmd: [ 'bash', '-c', 'install -d ../install/src/www/api && cd ../../ops-restd/build/opslib && PYTHONPATH=../../../../stage/lib/python2.7/dist-packages:${PYTHONPATH} python apidocgen.py ../../../../stage/usr/share/openvswitch/vswitch.extschema ../../../../stage/usr/share/openvswitch/vswitch.xml > ../../../ops-restd-json/install/src/www/api/ops-restapi.json' ]
files:
parts/ops-restd/src/server.crt: etc/ssl/certs
parts/ops-restd/src/server-private.key: etc/ssl/certs
after: [ ops, ops-openvswitch, ops-restd ]
ops-tempd:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-tempd
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
ops-fand:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-fand
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
ops-powerd:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-powerd
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
ops-pmd:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-pmd
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
ops-portd:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-portd
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
ops-vland:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-vland
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
build-packages: [ libreadline-dev ]
ops-ledd:
plugin: cmake
configflags:
- "-DCMAKE_INSTALL_PREFIX=/usr"
source: git://github.com/open-switch/ops-ledd
after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
#
# TODO: The following fail compile due to conflicting definitions of CTRL(c)
#
# ops-intfd:
# plugin: cmake
# configflags:
# - "-DCMAKE_INSTALL_PREFIX=/usr"
# source: git://github.com/open-switch/ops-intfd
# after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
# ops-arpmgrd:
# plugin: cmake
# configflags:
# - "-DCMAKE_INSTALL_PREFIX=/usr"
# source: git://github.com/open-switch/ops-arpmgrd
# after: [ ops-openvswitch, ops-cli, ops-hw-config, ops-supportability ]
#
# TODO: Figure out how to generate version_detail.yaml
#