Skip to content

Installing from source

Alex Lobunets edited this page Aug 20, 2014 · 10 revisions

Prerequisites

The toolkit requires the latest stable Go release. If you don't have Go installed, read the official Go installation guide.

Compiling components

Create a folder for your installation and change to it (all subsequent commands should be executed from this folder):

mkdir patchwork

Install dependencies:

GOPATH=`pwd` go get git.eclipse.org/gitroot/paho/org.eclipse.paho.mqtt.golang.git
GOPATH=`pwd` go get github.com/bmizerany/pat

// Optionally (to be released soon)
GOPATH=`pwd` go get github.com/andrewtj/dnssd

Checkout the sources from Github treating the current folder as a GOPATH directory:

GOPATH=`pwd` go get -d github.com/patchwork-toolkit/patchwork

Build the main Patchwork components (device gateway, devices catalog and services catalog binaries):

GOPATH=`pwd` go install github.com/patchwork-toolkit/patchwork/cmd/device-gateway
GOPATH=`pwd` go install github.com/patchwork-toolkit/patchwork/cmd/device-catalog
GOPATH=`pwd` go install github.com/patchwork-toolkit/patchwork/cmd/service-catalog

As a result, the corresponding binaries will be created in the bin folder in the project folder:

bin/
bin/device-catalog
bin/device-gateway
bin/service-catalog

What's next?

Now you have Patchwork Toolkit binaries. The next step is configuration of the toolkit. Please, proceed to Getting Started.