mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-07-01 17:52:40 +00:00
vc:sandbox: rename newcontainer to fetchcontainer.
The containers is not new but fech from an existing one. Signed-off-by: Jose Carlos Venegas Munoz <jose.carlos.venegas.munoz@intel.com>
This commit is contained in:
parent
618cfbf1db
commit
0d80202573
@ -38,7 +38,7 @@ func TestFilesystemCreateAllResourcesSuccessful(t *testing.T) {
|
||||
containers: map[string]*Container{},
|
||||
}
|
||||
|
||||
if err := sandbox.newContainers(); err != nil {
|
||||
if err := sandbox.fetchContainers(); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
|
@ -925,7 +925,7 @@ func fetchSandbox(ctx context.Context, sandboxID string) (sandbox *Sandbox, err
|
||||
|
||||
// This sandbox already exists, we don't need to recreate the containers in the guest.
|
||||
// We only need to fetch the containers from storage and create the container structs.
|
||||
if err := sandbox.newContainers(); err != nil {
|
||||
if err := sandbox.fetchContainers(); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
@ -1257,7 +1257,7 @@ func (s *Sandbox) addContainer(c *Container) error {
|
||||
// adds them to the sandbox. It does not create the containers
|
||||
// in the guest. This should only be used when fetching a
|
||||
// sandbox that already exists.
|
||||
func (s *Sandbox) newContainers() error {
|
||||
func (s *Sandbox) fetchContainers() error {
|
||||
for _, contConfig := range s.config.Containers {
|
||||
c, err := newContainer(s, contConfig)
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user