Skip to content

Add support for OCI labels on image/bundle push#552

Merged
joaopapereira merged 9 commits intocarvel-dev:developfrom
phenixblue:add-labels-for-bundles-and-images
Aug 3, 2023
Merged

Add support for OCI labels on image/bundle push#552
joaopapereira merged 9 commits intocarvel-dev:developfrom
phenixblue:add-labels-for-bundles-and-images

Conversation

@phenixblue
Copy link
Contributor

@phenixblue phenixblue commented Jul 26, 2023

This adds the ability for users to specify OCI labels that will be added to the generated OCI artifact (bundle/image) during a push operation.

Fixes #153

Example:

$ imgpkg push -b index.docker.io/jmsearcy/example-bundle:v1.0.3 -l foo.bar=baz -f ../../tmp/imgpkg-test

The resulting OCI artifact can be inspected as such to show the labels added:

$ regctl image inspect jmsearcy/example-bundle:v1.0.3

{
  "created": "0001-01-01T00:00:00Z",
  "architecture": "",
  "os": "",
  "config": {
    "Labels": {
      "dev.carvel.imgpkg.bundle": "true",
      "foo.bar": "baz",
    }
  },
  "rootfs": {
    "type": "layers",
    "diff_ids": [
      "sha256:f77fc57aa0878a70576e6b45c74ce5a7070219687b92fe073f632d71b7b107f8"
    ]
  },
  "history": [
    {
      "created": "0001-01-01T00:00:00Z",
      "created_by": "imgpkg",
      "author": "imgpkg"
    }
  ]
}

Signed-off-by: Joe Searcy <joe@twr.io>
Signed-off-by: Joe Searcy <joe@twr.io>
@phenixblue phenixblue force-pushed the add-labels-for-bundles-and-images branch from 00e3d96 to 63e8348 Compare July 26, 2023 19:57
@phenixblue phenixblue had a problem deploying to TanzuNet Registry Dev e2e July 26, 2023 19:57 — with GitHub Actions Failure
@phenixblue phenixblue had a problem deploying to TanzuNet Registry Dev e2e July 26, 2023 20:00 — with GitHub Actions Failure
@phenixblue
Copy link
Contributor Author

Related to #412

Signed-off-by: Joe Searcy <joe@twr.io>
@phenixblue phenixblue temporarily deployed to GCR e2e July 30, 2023 06:46 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to TanzuNet Registry Dev e2e July 30, 2023 06:46 — with GitHub Actions Inactive
Signed-off-by: Joe Searcy <joe@twr.io>
Signed-off-by: Joe Searcy <joe@twr.io>
@phenixblue phenixblue temporarily deployed to TanzuNet Registry Dev e2e August 1, 2023 21:34 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to GCR e2e August 1, 2023 21:34 — with GitHub Actions Inactive
Copy link
Member

@joaopapereira joaopapereira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change looks good to me. Added some questions and suggestions.

@phenixblue phenixblue temporarily deployed to TanzuNet Registry Dev e2e August 2, 2023 17:32 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to GCR e2e August 2, 2023 17:32 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to GCR e2e August 2, 2023 18:34 — with GitHub Actions Inactive
@phenixblue phenixblue had a problem deploying to TanzuNet Registry Dev e2e August 2, 2023 18:34 — with GitHub Actions Failure
phenixblue and others added 3 commits August 2, 2023 14:40
Co-authored-by: João Pereira <joaopapereira@gmail.com>
Signed-off-by: Joe Searcy <joe@twr.io>
Signed-off-by: Joe Searcy <joe@twr.io>
Signed-off-by: Joe Searcy <joe@twr.io>
@phenixblue phenixblue force-pushed the add-labels-for-bundles-and-images branch from 4ff82e7 to f5d15ff Compare August 2, 2023 18:41
@phenixblue phenixblue temporarily deployed to GCR e2e August 2, 2023 18:41 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to TanzuNet Registry Dev e2e August 2, 2023 18:41 — with GitHub Actions Inactive
Signed-off-by: Joe Searcy <joe@twr.io>
@phenixblue phenixblue had a problem deploying to TanzuNet Registry Dev e2e August 2, 2023 19:12 — with GitHub Actions Failure
@phenixblue phenixblue temporarily deployed to GCR e2e August 2, 2023 19:12 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to TanzuNet Registry Dev e2e August 2, 2023 20:43 — with GitHub Actions Inactive
@phenixblue phenixblue temporarily deployed to GCR e2e August 2, 2023 20:43 — with GitHub Actions Inactive
Copy link
Member

@joaopapereira joaopapereira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@joaopapereira joaopapereira merged commit f9723ee into carvel-dev:develop Aug 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Add annotations/labels to bundle

2 participants