Discover Packages
github.com/google/go-containerregistry
pkg
v1
random
package
Version:
v0.22.1
Opens a new window with list of versions in this module.
Published: Sep 4, 2026
License: Apache-2.0
Opens a new window with license information.
Imports: 13
Opens a new window with list of imports.
Imported by: 44 modules, 27 packages
The first number is the count of modules that contain a package that imports this one.
The module count is a better indicator of popularity than the package count.
A module with 100 importing packages is counted only once instead of 100 times,
reflecting the fact that the choice to use the package was likely made only once,
not 100 times.
A '?' means that the value hasn't been computed yet.
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package random provides a facility for synthesizing pseudo-random images.
func Image(byteSize, layers int64, options ...Option) (v1.Image, error)
func Index(byteSize, layers, count int64, options ...Option) (v1.ImageIndex, error)
func Layer(byteSize int64, mt types.MediaType, options ...Option) (v1.Layer, error)
type Option
Image returns a pseudo-randomly generated Image.
Index returns a pseudo-randomly generated ImageIndex with count images, each
having the given number of layers of size byteSize.
Layer returns a layer with pseudo-randomly generated content.
type Option func(opts *options)
Option is an optional parameter to the random functions
WithSource sets the random number generator source
Source Files
¶
Click to show internal directories.
Click to hide internal directories.