Rename Create to Init for containers to be less confusing

Signed-off-by: Matthew Heon <matthew.heon@gmail.com>
This commit is contained in:
Matthew Heon
2017-11-09 13:54:48 -05:00
parent 763e372649
commit 4bc3acc7aa
2 changed files with 3 additions and 3 deletions

View File

@ -83,7 +83,7 @@ func runCmd(c *cli.Context) error {
} }
logrus.Debug("new container created ", ctr.ID()) logrus.Debug("new container created ", ctr.ID())
if err := ctr.Create(); err != nil { if err := ctr.Init(); err != nil {
return err return err
} }
logrus.Debug("container storage created for %q", ctr.ID()) logrus.Debug("container storage created for %q", ctr.ID())

View File

@ -246,8 +246,8 @@ func (c *Container) teardownStorage() error {
return nil return nil
} }
// Create creates a container in the OCI runtime // Init creates a container in the OCI runtime
func (c *Container) Create() (err error) { func (c *Container) Init() (err error) {
c.lock.Lock() c.lock.Lock()
defer c.lock.Unlock() defer c.lock.Unlock()