21.1. Architecture Overview¶
Architecturally, dr-provision is split into several different packages:
define the data models that the other packages use, along with some common functionality that can be shared between the client and server side.
defines a client-side Go API for interacting with dr-provision.
provides our default CLI for interacting with dr-provision.
implements the core client code that all plugins should use to act as a dr-provision plugin.
Every valid dr-provision object has a Model that is implemented in this package. These models are authoritative, and their JSON serialization in Go is the canonical wire format.
The API package implements the reference Go client API for dr-provision. You should consult the go docs for the API at https://godoc.org/gitlab.com/rackn/provision for in-depth discussion on how to use the client API.
The CLI package implements the reference Go client CLI for dr-provision. The main program for drpcli includes this set of functions.
The plugin package implements the Go core functions needed to create a dr-provision plugin.