Documentation
¶
Overview ¶
Copyright 2017-2018 OneLedger
The overall running context. Initialized right away, but is mutable.
Contains the main variables.
Precedence:
- Default values
- Environment variables (like $OLROOT)
- Configuration files
- Command line arguments
- Overrides
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context struct {
Application persist.Access // Global Access to the application when it is running
Debug bool // DEBUG flag
DisablePasswords bool // DEBUG flag
NodeName string // Name of this instance
NodeAccountName string // TODO: Should be a list of accounts
NodeIdentity string
RootDir string // Working directory for this instance
RpcAddress string // rpc address
Transport string // socket vs grpc
AppAddress string // app address
BTCAddress string // Bitcoin node Address port
ETHAddress string // Ethereum node Address port
Sequence int64 // replay protection
}
var Current *Context
func NewContext ¶
Set the default values for any context variables here (and no where else)
func (*Context) GetApplication ¶
Click to show internal directories.
Click to hide internal directories.