env

package
v0.8.2 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2020 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package env provides a unified method to create environment for envexec

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBuilder

func NewBuilder(c Config) (pool.EnvBuilder, error)

NewBuilder build a environment builder

Types

type Config added in v0.8.1

type Config struct {
	ContainerInitPath string
	TmpFsParam        string
	NetShare          bool
	MountConf         string
	CgroupPrefix      string
	Logger
}

Config defines parameters to create environment builder

type Logger added in v0.8.1

type Logger interface {
	Debug(args ...interface{})
	Info(args ...interface{})
	Warn(args ...interface{})
	Error(args ...interface{})
}

Logger defines logger to print logs

type Mount

type Mount struct {
	Type     string `yaml:"type"`
	Source   string `yaml:"source"`
	Target   string `yaml:"target"`
	Readonly bool   `yaml:"readonly"`
	Data     string `yaml:"data"`
}

Mount defines single mount point configuration. type could be bind / tmpfs

type Mounts

type Mounts struct {
	Mount      []Mount `yaml:"mount"`
	WorkDir    string  `yaml:"workDir"`
	HostName   string  `yaml:"hostName"`
	DomainName string  `yaml:"domainName"`
	Proc       bool    `yaml:"proc"`
}

Mounts defines mount points for the container.

Jump to

Keyboard shortcuts

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