Documentation ¶
Overview ¶
Package stdinservice implements a service which, on request, executes a command on the client, passes data to its stdin and returns the result.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Factory ¶
func Factory(conf *fspb.ClientServiceConfig) (service.Service, error)
Factory is a service.Factory for StdinServices.
In response to every received sspb.InputMessage, a StdinService fires up a process, pipes the given input message to its stdin, waits for it to finish and sends the contents of stdout and stderr back to the server. The process is expected to finish relatively quickly.
conf.Config should be of proto type DaemonServiceConfig.
Types ¶
type StdinService ¶
type StdinService struct {
// contains filtered or unexported fields
}
StdinService implements a service.Service which runs a command one for each message received, passing data to it through stdin and getting the results through stdout/stderr.
func (*StdinService) ProcessMessage ¶
func (*StdinService) Stop ¶
func (s *StdinService) Stop() error