Documentation ¶
Index ¶
- Constants
- func Init(filename string) (err error)
- type Config
- type DockerConfig
- type KubernetesConfig
- type KubernetesManifestArgs
- type Service
- func (s *Service) DashedName() string
- func (s *Service) Docker() *DockerConfig
- func (s *Service) EnvFiles() []string
- func (s *Service) Kubernetes() *KubernetesConfig
- func (s *Service) Language() string
- func (s *Service) Name() string
- func (s *Service) Path() string
- func (s *Service) SyslogIdentifier() string
- func (s *Service) TargetNames() []string
- func (s *Service) Targets() []*Target
- type Target
- func (t *Target) Architecture() string
- func (t *Target) Directory() string
- func (t *Target) DockerRegistry() string
- func (t *Target) DockerRepository() string
- func (t *Target) Host() string
- func (t *Target) KubeContext() string
- func (t *Target) Name() string
- func (t *Target) Namespace() string
- func (t *Target) System() string
- func (t *Target) Username() string
Constants ¶
const ( LangGo = "go" SysDocker = "docker" SysKubernetes = "kubernetes" SysSystemd = "systemd" ArchARMv6 = "ARMv6" )
Service constants
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DockerConfig ¶
type DockerConfig struct {
// contains filtered or unexported fields
}
DockerConfig holds options related building the service using Docker
func (*DockerConfig) Args ¶
func (d *DockerConfig) Args() map[string]string
Args returns a map of arguments for the Dockerfile
func (*DockerConfig) Dockerfile ¶
func (d *DockerConfig) Dockerfile() string
Dockerfile returns the path to the Dockerfile
type KubernetesConfig ¶
type KubernetesConfig struct {
// contains filtered or unexported fields
}
KubernetesConfig holds options related to a Kubernetes deployment
func (*KubernetesConfig) ManifestArgs ¶
func (k *KubernetesConfig) ManifestArgs() *KubernetesManifestArgs
ManifestArgs returns data that should be given to the manifest template
func (*KubernetesConfig) Manifests ¶
func (k *KubernetesConfig) Manifests() []string
Manifests returns the paths of the Kubernetes manifest files
type KubernetesManifestArgs ¶
type KubernetesManifestArgs struct {
// contains filtered or unexported fields
}
KubernetesManifestArgs holds data that should be given to the manifest template
func (*KubernetesManifestArgs) NodePort ¶
func (a *KubernetesManifestArgs) NodePort() int
NodePort returns a non-zero int if a custom node port is set in the manifest args
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service is the microservice to be deployed
func (*Service) DashedName ¶
DashedName returns home-automation-foo for foo
func (*Service) Docker ¶
func (s *Service) Docker() *DockerConfig
Docker returns the docker configuration for the service
func (*Service) EnvFiles ¶
EnvFiles returns the env files that should be supplied to the service at runtime
func (*Service) Kubernetes ¶
func (s *Service) Kubernetes() *KubernetesConfig
Kubernetes returns the Kubernetes configuration for the service
func (*Service) SyslogIdentifier ¶
SyslogIdentifier returns the value that can be used in a systemd unit file.
func (*Service) TargetNames ¶
TargetNames returns the names of the service's targets
type Target ¶
type Target struct {
// contains filtered or unexported fields
}
Target is the destination server for the deployment
func (*Target) Architecture ¶
Architecture returns the target's architecture
func (*Target) DockerRegistry ¶
DockerRegistry returns the Docker registry that images should be pushed to to be deployed to the target
func (*Target) DockerRepository ¶
DockerRepository returns the name of the Docker repository that images should be in to be deployed to the target. In the image 192.168.1.1/jakewright/s-foo, jakewright is the repository.
func (*Target) KubeContext ¶
KubeContext returns the k8s context to use when interacting with the target
func (*Target) Namespace ¶
Namespace returns the k8s namespace to use when interacting with the target