hauler icon indicating copy to clipboard operation
hauler copied to clipboard

[RFE] Support Copying to Registries with Paths

Open ngearhart opened this issue 1 month ago • 0 comments

Is this RFE related to an Existing Problem? If so, please describe: This is related to https://github.com/rancherfederal/hauler/issues/232 as the implementation for this feature could solve both.

  • When trying to push to a registry that requires a prepended path, hauler will fail. For example, JFrog Artifactory's docker/OCI registry requires you push to oci://artifactory.example.com/registry-name (pushing to oci://artifactory.example.com directly will fail). The goal would be for hauler to support copying to "path-required" registries.

Describe Proposed Solution(s):

  • Add a --prepend-path feature to hauler store copy like hauler store copy --prepend-path registry-name registry://artifactory.example.com such that hauler would prepend that path to all image tags.

Describe Possible Alternatives:

  • Allow rewriting in Hauler manifests, like:
apiVersion: content.hauler.cattle.io/v1alpha1
kind: Images
metadata:
  name: test
spec:
  images:
    - name: registry1.dso.mil/ironbank/big-bang/argocd:v2.9.4
      rewrite: registry-name/ironbank/big-bang/argocd:v2.9.4

such that hauler store sync pulls registry1.dso.mil/ironbank/big-bang/argocd:v2.9.4 but saves it as registry-name/ironbank/big-bang/argocd:v2.9.4 in the store.

ngearhart avatar May 06 '24 16:05 ngearhart