{{if eq .PackageDescriptor.Package.Type "container"}}

{{ctx.Locale.Tr "packages.installation"}}

{{if eq .PackageDescriptor.Metadata.Type "helm"}}
helm pull oci://{{.PackageRegistryHost}}/{{.PackageDescriptor.Owner.LowerName}}/{{.PackageDescriptor.Package.LowerName}} --version {{.PackageDescriptor.Version.LowerVersion}}
{{else}} {{$separator := ":"}} {{if not .PackageDescriptor.Metadata.IsTagged}} {{$separator = "@"}} {{end}}
docker pull {{.PackageRegistryHost}}/{{.PackageDescriptor.Owner.LowerName}}/{{.PackageDescriptor.Package.LowerName}}{{$separator}}{{.PackageDescriptor.Version.LowerVersion}}
{{end}}
{{range .PackageDescriptor.Files}}{{if eq .File.LowerName "manifest.json"}}{{.Properties.GetByName "container.digest"}}{{end}}{{end}}
{{if .PackageDescriptor.Metadata.Manifests}}

{{ctx.Locale.Tr "packages.container.multi_arch"}}

{{range .PackageDescriptor.Metadata.Manifests}} {{/* "unknown/unknown" is attestation-manifest, so we should skip it */}} {{if ne .Platform "unknown/unknown"}} {{end}} {{end}}
{{ctx.Locale.Tr "packages.container.digest"}} {{ctx.Locale.Tr "packages.container.multi_arch"}} {{ctx.Locale.Tr "admin.packages.size"}}
{{StringUtils.TrimPrefix .Digest "sha256:" | ShortSha}} {{.Platform}} {{FileSize .Size}}
{{end}} {{if .PackageDescriptor.Metadata.Description}}

{{ctx.Locale.Tr "packages.about"}}

{{.PackageDescriptor.Metadata.Description}}
{{end}} {{if .PackageDescriptor.Metadata.ImageLayers}}

{{ctx.Locale.Tr "packages.container.layers"}}

{{range .PackageDescriptor.Metadata.ImageLayers}} {{end}}
{{.}}
{{end}} {{if .PackageDescriptor.Metadata.Labels}}

{{ctx.Locale.Tr "packages.container.labels"}}

{{range $key, $value := .PackageDescriptor.Metadata.Labels}} {{end}}
{{ctx.Locale.Tr "packages.container.labels.key"}} {{ctx.Locale.Tr "packages.container.labels.value"}}
{{$key}} {{$value}}
{{end}} {{end}}