Drop the "omitempty" tag from the "json" tag on struct members that are
themselves structs, since the JSON encoder doesn't actually do that, per
golang.org/x/tools/gopls/internal/analysis/modernize/cmd/modernize
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
When handling RUN instructions that use heredoc syntax, don't bother
interpolating environment variables and argument values, and let the
command that's running handle it.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Add the variant field, along with methods for setting and querying it,
and expose them in the `buildah config` and `buildah inspect` commands.
When setting an initial architecture for a container based on an image
which doesn't contain an architecture, or from "scratch", normalize the
architecture name we've been given, and set both it and the variant
field at the same time.
Provide normalized architecture+variant values in `buildah info`.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Descriptions of types that include the type names didn't always match
since we last renamed things.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Closes: #1272
Approved by: rhatdan
The HealthConfig.StartPeriod field was added to docker late in 2016.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Closes: #943
Approved by: TomSweeneyRedHat
Import more manifest and schema variables and types, and rename some of
them to incorporate version numbers.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Closes: #118
Approved by: rhatdan
Update comments which reference where the types in docker/types.go came
from to reflect renames of the upstream repositories. The contents of
the types themselves, since they are encoded into images that are kept
on disk, shouldn't change often, if ever.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Closes: #102
Approved by: rhatdan
Import the container.Config and container.HealthCheck API types, and the
nat.Port and nat.PortSet types from go-connections. Use the strslice
package from containers/image instead of rolling or importing our own.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Closes: #102
Approved by: rhatdan
Internalize the type declaration of a Docker image, so that we don't
need to pull in code when we just want to know how to parse out a JSON
object. Carry a copy of the license that covered the sources from which
the definitions came.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
Closes: #75
Approved by: nalind