Commit Graph

16 Commits

Author SHA1 Message Date
Nalin Dahyabhai 7aedebdccd modernize: JSON doesn't do "omitempty" structs, so stop asking
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>
2025-09-10 13:19:38 -04:00
Jan Kaluza a0a9ac6380 Switch common, storage and image to monorepo.
Signed-off-by: Jan Kaluza <jkaluza@redhat.com>
2025-08-29 15:04:28 +02:00
Kir Kolyshkin e8dba98314 ci: add nolintlint, fix found issues
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2025-04-07 13:02:39 -07:00
Nalin Dahyabhai 97382f9288 Don't expand RUN heredocs ourselves, let the shell do it
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>
2024-05-20 09:35:48 -04:00
Nalin Dahyabhai 9f9f32cedd config: support the variant field
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>
2021-11-05 09:37:00 -04:00
Nalin Dahyabhai f0cf07bb60 Move to containers/image v5.0.0
Bump to containers/image's 5.0 release.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>

Closes: #1902
Approved by: rhatdan
2019-10-28 15:15:34 +00:00
Miloslav Trmač 797e618cbe Update c/image to v4.0.1
This requires updating all import paths throughout.

Signed-off-by: Miloslav Trmač <mitr@redhat.com>

Closes: #1891
Approved by: vrothberg
2019-10-04 07:34:03 +00:00
Valentin Rothberg f60d06d817 docker: ignore "repeats json tag" lint error
Reported by golangci-lint.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>

Closes: #1678
Approved by: rhatdan
2019-06-19 11:33:36 +00:00
Valentin Rothberg a0d32e7fa0 docker/types.go: remove unused struct fields
Reported by golangci-lint.

Signed-off-by: Valentin Rothberg <rothberg@redhat.com>

Closes: #1624
Approved by: TomSweeneyRedHat
2019-06-17 18:45:00 +00:00
Nalin Dahyabhai 5aa416e20d Update some comments
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
2019-01-11 12:31:58 +00:00
Nalin Dahyabhai 377fd209d8 Add docker.HealthConfig.StartPeriod
The HealthConfig.StartPeriod field was added to docker late in 2016.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>

Closes: #943
Approved by: TomSweeneyRedHat
2018-11-21 12:56:24 +00:00
TomSweeneyRedHat 9af14c4540 Use manifest from container/image
Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>

Closes: #870
Approved by: rhatdan
2018-07-19 15:42:01 +00:00
Nalin Dahyabhai b7ccc2397b Import and namespace more types
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
2017-05-24 18:20:10 +00:00
Nalin Dahyabhai 6f4bd94b95 Update reference comments for docker types origins
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
2017-05-18 18:28:44 +00:00
Nalin Dahyabhai 58e56e3efc Import container.{Config,HealthCheck},nat.PortSet
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
2017-05-18 18:28:44 +00:00
Nalin Dahyabhai ce3505a4d7 Internalize some Docker types
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
2017-04-19 19:05:06 +00:00