Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add hyperkit doc #4632

Merged
merged 1 commit into from
Jun 28, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions pkg/drivers/hyperkit/driver.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ const (
"sudo chown root:wheel %s && sudo chmod u+s %s"
)

// Driver is the machine driver for Hyperkit
type Driver struct {
*drivers.BaseDriver
*pkgdrivers.CommonDriver
Expand All @@ -69,6 +70,7 @@ type Driver struct {
VSockPorts []string
}

// NewDriver creates a new driver for a host
func NewDriver(hostName, storePath string) *Driver {
return &Driver{
BaseDriver: &drivers.BaseDriver{
Expand Down Expand Up @@ -98,6 +100,7 @@ func (d *Driver) verifyRootPermissions() error {
return nil
}

// Create a host using the driver's config
func (d *Driver) Create() error {
if err := d.verifyRootPermissions(); err != nil {
return err
Expand Down Expand Up @@ -194,6 +197,7 @@ func (d *Driver) Remove() error {
return nil
}

// Restart a host
func (d *Driver) Restart() error {
return pkgdrivers.Restart(d)
}
Expand Down