stage0

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2015 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Enter added in v0.2.0

func Enter(cdir string, imageID *types.Hash, cmdline []string) error

Enter enters the container by exec()ing the stage1's /enter similar to /init /enter can expect to have its CWD set to the container root imageID and command are supplied to /enter on argv followed by any arguments

func Run

func Run(cfg Config, dir string)

Run actually runs the container by exec()ing the stage1 init inside the container filesystem.

func Setup

func Setup(cfg Config) (string, error)

Setup sets up a filesystem for a container based on the given config. The directory containing the filesystem is returned, and any error encountered.

Types

type Config

type Config struct {
	Store         *cas.Store // store containing all of the configured application images
	ContainersDir string     // root directory for rocket containers
	Stage1Image   types.Hash // stage1 image containing usable /init and /enter entrypoints
	Debug         bool
	// TODO(jonboulle): These images are partially-populated hashes, this should be clarified.
	Images           []types.Hash   // application images
	Volumes          []types.Volume // list of volumes that rocket can provide to applications
	PrivateNet       bool           // container should have its own network stack
	SpawnMetadataSvc bool           // launch metadata service
}

Jump to

Keyboard shortcuts

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