mirror of
https://github.com/containers/podman.git
synced 2025-12-08 06:39:05 +08:00
Rename localRuntime to runtime in cmd/podman
Signed-off-by: baude <bbaude@redhat.com>
This commit is contained in:
@@ -64,11 +64,11 @@ specified, the image with the 'latest' tag (if it exists) is pulled
|
||||
// pullCmd gets the data from the command line and calls pullImage
|
||||
// to copy an image from a registry to a local machine
|
||||
func pullCmd(c *cli.Context) error {
|
||||
localRuntime, err := adapter.GetRuntime(c)
|
||||
runtime, err := adapter.GetRuntime(c)
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "could not get runtime")
|
||||
}
|
||||
defer localRuntime.Runtime.Shutdown(false)
|
||||
defer runtime.Runtime.Shutdown(false)
|
||||
|
||||
args := c.Args()
|
||||
if len(args) == 0 {
|
||||
@@ -116,14 +116,14 @@ func pullCmd(c *cli.Context) error {
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "error parsing %q", image)
|
||||
}
|
||||
newImage, err := localRuntime.LoadFromArchiveReference(getContext(), srcRef, c.String("signature-policy"), writer)
|
||||
newImage, err := runtime.LoadFromArchiveReference(getContext(), srcRef, c.String("signature-policy"), writer)
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "error pulling image from %q", image)
|
||||
}
|
||||
imgID = newImage[0].ID()
|
||||
} else {
|
||||
authfile := getAuthFile(c.String("authfile"))
|
||||
newImage, err := localRuntime.New(getContext(), image, c.String("signature-policy"), authfile, writer, &dockerRegistryOptions, image2.SigningOptions{}, true)
|
||||
newImage, err := runtime.New(getContext(), image, c.String("signature-policy"), authfile, writer, &dockerRegistryOptions, image2.SigningOptions{}, true)
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "error pulling image %q", image)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user