Documentation
¶
Index ¶
- Variables
- func CheckExists(stackName string) (bool, error)
- func GenerateKeyAndPeerId() (privateKey string, peerId string)
- func GenerateSwarmKey() string
- func InitStack(stackName string, memberCount int, options *InitOptions) error
- func ListStacks() ([]string, error)
- func NewFireflyConfigs(stack *Stack) map[string]*FireflyConfig
- func WriteFireflyConfig(config *FireflyConfig, filePath string) error
- type AdminServerConfig
- type BasicAuth
- type BlockchainConfig
- type CommonDBConfig
- type DataExchangeConfig
- type DataExchangeListenerConfig
- type DataExchangePeerConfig
- type DatabaseConfig
- type DatabaseSelection
- type DependsOn
- type DockerComposeConfig
- type EthconnectConfig
- type EthereumConfig
- type FireflyConfig
- type FireflyIPFSConfig
- type HealthCheck
- type HttpEndpointConfig
- type HttpServerConfig
- type InitOptions
- type LogConfig
- type LoggingConfig
- type Member
- type MigrationsConfig
- type NodeConfig
- type OrgConfig
- type PeerConfig
- type PublicStorageConfig
- type Service
- type Stack
- func (s *Stack) GenerateDataExchangeHTTPSConfig(memberId string) *DataExchangePeerConfig
- func (s *Stack) PrintStackInfo(verbose bool) error
- func (s *Stack) RemoveStack(verbose bool) error
- func (s *Stack) ResetStack(verbose bool) error
- func (s *Stack) StackHasRunBefore() (bool, error)
- func (s *Stack) StartStack(fancyFeatures bool, verbose bool, options *StartOptions) error
- func (s *Stack) StopStack(verbose bool) error
- func (s *Stack) UpgradeStack(verbose bool) error
- type StartOptions
- type UIConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var DBSelectionStrings = []string{"postgres", "sqlite3"}
View Source
var StacksDir = filepath.Join(homeDir, ".firefly", "stacks")
Functions ¶
func CheckExists ¶
func GenerateKeyAndPeerId ¶
func GenerateSwarmKey ¶
func GenerateSwarmKey() string
func ListStacks ¶ added in v0.0.13
func NewFireflyConfigs ¶
func NewFireflyConfigs(stack *Stack) map[string]*FireflyConfig
func WriteFireflyConfig ¶
func WriteFireflyConfig(config *FireflyConfig, filePath string) error
Types ¶
type AdminServerConfig ¶ added in v0.0.17
type BlockchainConfig ¶
type BlockchainConfig struct { Type string `yaml:"type,omitempty"` Ethereum *EthereumConfig `yaml:"ethereum,omitempty"` }
type CommonDBConfig ¶ added in v0.0.21
type CommonDBConfig struct { URL string `yaml:"url,omitempty"` Migrations *MigrationsConfig `yaml:"migrations,omitempty"` }
type DataExchangeConfig ¶
type DataExchangeConfig struct { Type string `yaml:"type,omitempty"` HTTPS *HttpEndpointConfig `yaml:"https,omitempty"` }
type DataExchangePeerConfig ¶
type DataExchangePeerConfig struct { API *DataExchangeListenerConfig `json:"api,omitempty"` P2P *DataExchangeListenerConfig `json:"p2p,omitempty"` Peers []*PeerConfig `json:"peers"` }
type DatabaseConfig ¶
type DatabaseConfig struct { Type string `yaml:"type,omitempty"` PostgreSQL *CommonDBConfig `yaml:"postgres,omitempty"` SQLite3 *CommonDBConfig `yaml:"sqlite3,omitempty"` }
type DatabaseSelection ¶ added in v0.0.21
type DatabaseSelection int
const ( PostgreSQL DatabaseSelection = iota SQLite3 )
func DatabaseSelectionFromString ¶ added in v0.0.21
func DatabaseSelectionFromString(s string) (DatabaseSelection, error)
func (DatabaseSelection) String ¶ added in v0.0.21
func (db DatabaseSelection) String() string
type DockerComposeConfig ¶
type DockerComposeConfig struct { Version string `yaml:"version,omitempty"` Services map[string]*Service `yaml:"services,omitempty"` Volumes map[string]struct{} `yaml:"volumes,omitempty"` }
func CreateDockerCompose ¶
func CreateDockerCompose(stack *Stack) *DockerComposeConfig
type EthconnectConfig ¶
type EthereumConfig ¶
type EthereumConfig struct {
Ethconnect *EthconnectConfig `yaml:"ethconnect,omitempty"`
}
type FireflyConfig ¶
type FireflyConfig struct { Log *LogConfig `yaml:"log,omitempty"` Debug *HttpServerConfig `yaml:"debug,omitempty"` HTTP *HttpServerConfig `yaml:"http,omitempty"` Admin *AdminServerConfig `yaml:"admin,omitempty"` UI *UIConfig `yaml:"ui,omitempty"` Node *NodeConfig `yaml:"node,omitempty"` Org *OrgConfig `yaml:"org,omitempty"` Blockchain *BlockchainConfig `yaml:"blockchain,omitempty"` Database *DatabaseConfig `yaml:"database,omitempty"` P2PFS *PublicStorageConfig `yaml:"publicstorage,omitempty"` DataExchange *DataExchangeConfig `yaml:"dataexchange,omitempty"` }
func ReadFireflyConfig ¶
func ReadFireflyConfig(filePath string) (*FireflyConfig, error)
type FireflyIPFSConfig ¶
type FireflyIPFSConfig struct { API *HttpEndpointConfig `yaml:"api,omitempty"` Gateway *HttpEndpointConfig `yaml:"gateway,omitempty"` }
type HealthCheck ¶
type HttpEndpointConfig ¶
type HttpServerConfig ¶
type InitOptions ¶ added in v0.0.16
type LoggingConfig ¶
type Member ¶
type Member struct { ID string `json:"id,omitempty"` Index *int `json:"index,omitempty"` Address string `json:"address,omitempty"` PrivateKey string `json:"privateKey,omitempty"` ExposedFireflyPort int `json:"exposedFireflyPort,omitempty"` ExposedFireflyAdminPort int `json:"exposedFireflyAdminPort,omitempty"` ExposedEthconnectPort int `json:"exposedEthconnectPort,omitempty"` ExposedPostgresPort int `json:"exposedPostgresPort,omitempty"` ExposedDataexchangePort int `json:"exposedDataexchangePort,omitempty"` ExposedIPFSApiPort int `json:"exposedIPFSApiPort,omitempty"` ExposedIPFSGWPort int `json:"exposedIPFSGWPort,omitempty"` ExposedUIPort int `json:"exposedUiPort ,omitempty"` }
type MigrationsConfig ¶
type NodeConfig ¶
type NodeConfig struct {
Name string `yaml:"name,omitempty"`
}
type PeerConfig ¶
type PublicStorageConfig ¶
type PublicStorageConfig struct { Type string `yaml:"type,omitempty"` IPFS *FireflyIPFSConfig `yaml:"ipfs,omitempty"` }
type Service ¶
type Service struct { Image string `yaml:"image,omitempty"` Build string `yaml:"build,omitempty"` Command string `yaml:"command,omitempty"` Environment map[string]string `yaml:"environment,omitempty"` Volumes []string `yaml:"volumes,omitempty"` Ports []string `yaml:"ports,omitempty"` DependsOn map[string]map[string]string `yaml:"depends_on,omitempty"` HealthCheck *HealthCheck `yaml:"healthcheck,omitempty"` Logging *LoggingConfig `yaml:"logging,omitempty"` }
type Stack ¶
type Stack struct { Name string `json:"name,omitempty"` Members []*Member `json:"members,omitempty"` SwarmKey string `json:"swarmKey,omitempty"` ExposedGanachePort int `json:"exposedGanachePort,omitempty"` Database string `json:"database"` }
func (*Stack) GenerateDataExchangeHTTPSConfig ¶
func (s *Stack) GenerateDataExchangeHTTPSConfig(memberId string) *DataExchangePeerConfig
func (*Stack) PrintStackInfo ¶ added in v0.0.13
func (*Stack) RemoveStack ¶
func (*Stack) ResetStack ¶
func (*Stack) StackHasRunBefore ¶ added in v0.0.17
func (*Stack) StartStack ¶
func (s *Stack) StartStack(fancyFeatures bool, verbose bool, options *StartOptions) error
func (*Stack) UpgradeStack ¶ added in v0.0.13
type StartOptions ¶ added in v0.0.16
type StartOptions struct {
NoPull bool
}
Click to show internal directories.
Click to hide internal directories.