exec

package
v0.15.2 Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2022 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package exec provides a data source implementation that can execute external commands and return its standard output for import or importstr use.

Index

Constants

View Source
const (
	Scheme = "exec"
)

Scheme is scheme supported by this data source

Variables

This section is empty.

Functions

func New

func New(name string, configVar string) ds.DataSourceWithLifecycle

New creates a new exec data source

Types

type Config

type Config struct {
	Command    string            `json:"command"`              // the executable that is run
	Args       []string          `json:"args,omitempty"`       // arguments to be passed to the command
	Env        map[string]string `json:"env,omitempty"`        // environment for the command
	Stdin      string            `json:"stdin,omitempty"`      // standard input to pass to the command
	Timeout    string            `json:"timeout,omitempty"`    // command timeout as a duration string
	InheritEnv bool              `json:"inheritEnv,omitempty"` // Inherit env from the parent(qbec) process
	// contains filtered or unexported fields
}

Config is the configuration of the data source.

Jump to

Keyboard shortcuts

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