types

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 5, 2021 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Compose

type Compose struct {
	Version  string              `yaml:"version"`
	Services map[string]Service  `yaml:"services"`
	Networks map[string]Networks `yaml:"networks"`
	Volumes  map[string]Volumes  `yaml:"volumes"`
}

Yaml2Go

type Config

type Config struct {
	Principal      string
	LogLevel       string
	MinVersion     string
	AppName        string
	EnableSyslog   bool
	Hostname       string
	Listen         string
	Domain         string
	Credentials    UserCredentials
	PrefixHostname string
	PrefixTaskName string
	CPU            float64
	Memory         float64
	RedisServer    string
	RedisClient    *goredis.Client
	RedisCTX       context.Context
}

Config is a struct of the framework configuration

type Deploy

type Deploy struct {
	Resources struct {
		Limits struct {
			CPUs   string `yaml:"cpus"`
			Memory string `yaml:"memory"`
		} `yaml:"limits"`
	} `yaml:"resources"`
}

type ErrorMsg

type ErrorMsg struct {
	Message  string
	Number   int
	Function string
}

ErrorMsg hold the structure of error messages

type Networks

type Networks struct {
	External bool   `yaml:"external"`
	Name     string `yaml:"name"`
	Driver   string `yaml:"driver"`
}

type Service

type Service struct {
	Network     []string               `yaml:"network"`
	Build       string                 `yaml:"build"`
	Restart     string                 `yaml:"restart"`
	Volumes     []string               `yaml:"volumes"`
	Environment []string               `yaml:"environment"`
	DependsOn   []string               `yaml:"depends_on"`
	Ports       []string               `yaml:"ports"`
	Image       string                 `yaml:"image"`
	Labels      map[string]interface{} `yaml:"labels"`
	NetworkMode string                 `yaml:"network_mode"`
	Privileged  bool                   `yaml:"priviliged"`
	Command     []string               `yaml:"command"`
	Deploy      Deploy                 `yaml:"deploy"`
	Hostname    string                 `yaml:"hostname"`
}

Web

type UserCredentials

type UserCredentials struct {
	Username string
	Password string
}

UserCredentials - The Username and Password to authenticate against this framework

type Volumes

type Volumes struct {
	Driver string `yaml:"driver"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL