Happy is only supported on Linux due to its strong dependence on Linux network namespaces.
Install
- Install required libraries:
sudo apt-get install python-setuptools bridge-utils python-lockfile python-psutil make
- Clone the repository:
git clone https://github.com/openweave/happy.git
- Install Happy:
Thecd happy
make
make
command performs two tasks:- Creates a Happy python package at
/usr/local/lib/python2.7/dist-packages
- Copies Happy shell scripts to
/usr/local/bin
- Creates a Happy python package at
- Validate the installation by running a Happy command:
happy-state
State Name: happy
NETWORKS Name Type State Prefixes
NODES Name Interface Type IPs
Weave support
Happy supports Weave via OpenWeave, which requires an OpenWeave build and some additional configuration. The quickest way to integrate OpenWeave with Happy is to build the standalone application.
- Install the build toolchain and all dependencies required for OpenWeave:
sudo apt-get update
sudo apt-get install -y autotools-dev build-essential git lcov /
libdbus-1-dev libglib2.0-dev libssl-dev /
libudev-dev python2.7 python-software-properties
sudo apt-get install -y --force-yes gcc-arm-none-eabi
sudo apt-get update -qq
- Clone the OpenWeave repository:
git clone https://github.com/openweave/openweave-core.git
- Build the standalone OpenWeave application:
cd <path-to-openweave-core>
make -f Makefile-Standalone
- Set the Weave path in the Happy configuration:
happy-configuration weave_path <path-to-openweave-core>/build/x86_64-unknown-linux-gnu/src/test-apps
- Update the
$PATH
environment variable so it knows where to find Happy-related binaries for Weave:export PATH=$PATH:<path-to-openweave-core>/src/test-apps/happy/bin
- Test the configuration. You should be able to run Weave commands for Happy:
weave-state
State Name: weave
NODES Name Weave Node Id Pairing Code
FABRIC Fabric Id Global Prefix
Uninstall
- Ensure all virtual nodes and networks are deleted:
happy-state-delete
- Uninstall Happy:
cd <path-to-happy>
make uninstall
- Delete any other remaining Happy files:
rm -f ~/.happy_state.json
rm -f ~/.happy_conf.json
rm -f ~/.happy_state.json.lock
cd /usr/local/lib/python2.7/dist-packages
rm -f happy*
If you use an advanced feature like parallel states, each state should be individually deleted. See Uninstall with parallel states for more information.