provision: github.com/digitalrebar/provision/server Index | Files

package server

import "github.com/digitalrebar/provision/server"

Package server DigitalRebar Provision Server

An RestFUL API-driven Provisioner and DHCP server

Terms Of Service:

There are no TOS at this moment, use at your own risk we take no responsibility

Schemes: https
BasePath: /api/v3
Version: 0.1.0
License: APL https://raw.githubusercontent.com/digitalrebar/digitalrebar/master/LICENSE.md
Contact: Greg Althaus<greg@rackn.com> http://rackn.com

Security:
  - basicAuth: []
  - Bearer: []

Consumes:
- application/json

Produces:
- application/json

swagger:meta

Index

Package Files

assets.go cert.go server.go

func ExtractAssets Uses

func ExtractAssets(replaceRoot, fileRoot string) error

func Server Uses

func Server(c_opts *ProgOpts)

type ProgOpts Uses

type ProgOpts struct {
    VersionFlag         bool   `long:"version" description:"Print Version and exit"`
    DisableTftpServer   bool   `long:"disable-tftp" description:"Disable TFTP server"`
    DisableProvisioner  bool   `long:"disable-provisioner" description:"Disable provisioner"`
    DisableDHCP         bool   `long:"disable-dhcp" description:"Disable DHCP server"`
    DisablePXE          bool   `long:"disable-pxe" description:"Disable PXE/BINL server"`
    StaticPort          int    `long:"static-port" description:"Port the static HTTP file server should listen on" default:"8091"`
    TftpPort            int    `long:"tftp-port" description:"Port for the TFTP server to listen on" default:"69"`
    ApiPort             int    `long:"api-port" description:"Port for the API server to listen on" default:"8092"`
    DhcpPort            int    `long:"dhcp-port" description:"Port for the DHCP server to listen on" default:"67"`
    PxePort             int    `long:"pxe-port" description:"Port for the PXE/BINL server to listen on" default:"4011"`
    UnknownTokenTimeout int    `long:"unknown-token-timeout" description:"The default timeout in seconds for the machine create authorization token" default:"600"`
    KnownTokenTimeout   int    `long:"known-token-timeout" description:"The default timeout in seconds for the machine update authorization token" default:"3600"`
    OurAddress          string `long:"static-ip" description:"IP address to advertise for the static HTTP file server" default:"192.168.124.11"`
    ForceStatic         bool   `long:"force-static" description:"Force the system to always use the static IP."`

    BackEndType    string `long:"backend" description:"Storage to use for persistent data. Can be either 'consul', 'directory', or a store URI" default:"directory"`
    LocalContent   string `long:"local-content" description:"Storage to use for local overrides." default:"directory:///etc/dr-provision?codec=yaml"`
    DefaultContent string `long:"default-content" description:"Store URL for local content" default:"file:///usr/share/dr-provision/default.yaml?codec=yaml"`

    BaseRoot        string `long:"base-root" description:"Base directory for other root dirs." default:"/var/lib/dr-provision"`
    DataRoot        string `long:"data-root" description:"Location we should store runtime information in" default:"digitalrebar"`
    PluginRoot      string `long:"plugin-root" description:"Directory for plugins" default:"plugins"`
    LogRoot         string `long:"log-root" description:"Directory for job logs" default:"job-logs"`
    SaasContentRoot string `long:"saas-content-root" description:"Directory for additional content" default:"saas-content"`
    FileRoot        string `long:"file-root" description:"Root of filesystem we should manage" default:"tftpboot"`
    ReplaceRoot     string `long:"replace-root" description:"Root of filesystem we should use to replace embedded assets" default:"replace"`

    DevUI          string `long:"dev-ui" description:"Root of UI Pages for Development"`
    UIUrl          string `long:"ui-url" description:"URL to redirect to UI" default:"https://rackn.github.io/provision-ux"`
    DhcpInterfaces string `long:"dhcp-ifs" description:"Comma-seperated list of interfaces to listen for DHCP packets" default:""`
    DefaultStage   string `long:"default-stage" description:"The default stage for the nodes" default:"none"`
    DefaultBootEnv string `long:"default-boot-env" description:"The default bootenv for the nodes" default:"local"`
    UnknownBootEnv string `long:"unknown-boot-env" description:"The unknown bootenv for the system.  Should be \"ignore\" or \"discovery\"" default:"ignore"`

    DebugBootEnv  int    `long:"debug-bootenv" description:"Debug level for the BootEnv System - 0 = off, 1 = info, 2 = debug" default:"0"`
    DebugDhcp     int    `long:"debug-dhcp" description:"Debug level for the DHCP Server - 0 = off, 1 = info, 2 = debug" default:"0"`
    DebugRenderer int    `long:"debug-renderer" description:"Debug level for the Template Renderer - 0 = off, 1 = info, 2 = debug" default:"0"`
    DebugFrontend int    `long:"debug-frontend" description:"Debug level for the Frontend - 0 = off, 1 = info, 2 = debug" default:"1"`
    DebugPlugins  int    `long:"debug-plugins" description:"Debug level for the Plug-in layer - 0 = off, 1 = info, 2 = debug" default:"0"`
    TlsKeyFile    string `long:"tls-key" description:"The TLS Key File" default:"server.key"`
    TlsCertFile   string `long:"tls-cert" description:"The TLS Cert File" default:"server.crt"`
    UseOldCiphers bool   `long:"use-old-ciphers" description:"Use Original Less Secure Cipher List"`
    DrpId         string `long:"drp-id" description:"The id of this Digital Rebar Provision instance" default:""`

    BaseTokenSecret     string `long:"base-token-secret" description:"Auth Token secret to allow revocation of all tokens" default:""`
    SystemGrantorSecret string `long:"system-grantor-secret" description:"Auth Token secret to allow revocation of all Machine tokens" default:""`
}

Package server imports 27 packages (graph). Updated 2017-12-11. Refresh now. Tools for package owners.