windows

package
v0.0.0-...-f19ae85 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2015 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	Name string
	Conf common.Conf
}

Service represents a service running on the current system

func NewService

func NewService(name string, conf common.Conf) *Service

NewService returns a new Service type

func (*Service) Exists

func (s *Service) Exists() bool

Exists returns whether the service configuration exists in the init directory with the same content that this Service would have if installed. TODO (gabriel-samfira): 2014-07-30 bug 1350171 Needs a proper implementation when testing is improved

func (*Service) Install

func (s *Service) Install() error

Install installs and starts the service.

func (*Service) InstallCommands

func (s *Service) InstallCommands() ([]string, error)

InstallCommands returns shell commands to install and start the service.

func (*Service) Installed

func (s *Service) Installed() bool

Installed returns whether the service is installed

func (*Service) Remove

func (s *Service) Remove() error

Remove deletes the service.

func (*Service) Running

func (s *Service) Running() bool

Running returns true if the Service appears to be running.

func (*Service) Start

func (s *Service) Start() error

Start starts the service.

func (*Service) Status

func (s *Service) Status() (string, error)

Status gets the service status

func (*Service) Stop

func (s *Service) Stop() error

Stop stops the service.

func (*Service) StopAndRemove

func (s *Service) StopAndRemove() error

StopAndRemove stops the service and then deletes the service.

func (*Service) UpdateConfig

func (s *Service) UpdateConfig(conf common.Conf)

Jump to

Keyboard shortcuts

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