Documentation
¶
Index ¶
- func NewCompose(version string, services ...Service) (*composeConfig, error)
- type HealthCheck
- type Network
- type Service
- func (s *Service) AddEnvironment(key, value string) *Service
- func (s *Service) AddPort(host, container string) *Service
- func (s *Service) AddVolume(volume Volume) *Service
- func (s *Service) DependsOn(services ...Service) *Service
- func (s *Service) SetContainerName(name string) *Service
- func (s *Service) SetHealthCheck(test []string, interval, timeout string, retries int) *Service
- func (s *Service) SetImage(image string) *Service
- func (s *Service) SetRestartPolicy(policy string) *Service
- type Volume
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCompose ¶ added in v0.0.3
NewCompose crea una nueva configuración de docker-compose
Types ¶
type HealthCheck ¶ added in v0.0.4
HealthCheck representa la configuración de healthcheck
type Network ¶ added in v0.0.2
type Network struct {
Name string `yaml:"-"`
Driver string `yaml:"driver,omitempty"`
Options map[string]string `yaml:"options,omitempty"`
}
Network representa una red en docker-compose
type Service ¶ added in v0.0.2
type Service struct {
// contains filtered or unexported fields
}
Service representa un servicio en docker-compose
func NewService ¶ added in v0.0.2
NewService crea una nueva configuración de servicio
func (*Service) AddEnvironment ¶ added in v0.0.2
AddEnvironment añade una variable de entorno al servicio
func (*Service) SetContainerName ¶ added in v0.0.4
SetContainerName establece el nombre del contenedor
func (*Service) SetHealthCheck ¶ added in v0.0.4
SetHealthCheck configura el healthcheck del servicio
func (*Service) SetRestartPolicy ¶ added in v0.0.4
SetRestartPolicy establece la política de reinicio del servicio
Click to show internal directories.
Click to hide internal directories.