gitlab container registry would need to support Flux media types
We get this error when using Flux to push an OCI registry artifact to a container registry under registry.gitlab.com:
flux push artifact oci://registry.gitlab.com/sylva-projects/sylva-core/kustomize-units:test --path=. --source=git@gitlab.com:sylva-projects/sylva-core.git --revision=kustomize-units-oci-artifact/0574980c2e57149cb5879c27c61cba2551040e59
► pushing artifact to registry.gitlab.com/sylva-projects/sylva-core/kustomize-units:tmorin-test
✗ pushing artifact failed: pushing artifact failed: PUT https://registry.gitlab.com/v2/sylva-projects/sylva-core/kustomize-units/manifests/tmorin-test: MANIFEST_INVALID: manifest invalid; unknown media type: application/vnd.cncf.flux.config.v1+json
Flux CD maintainer Stefan Prodan explained that gitlab.com registry could possibly be configured to accept some media types that are used by Flux:
Starting with Flux 0.40 the artifacts produced by the CLI are proper OCI artifacts and looks like GitLab doesn't support that.
The OCI artifacts produced with flux push artifact have the following media types:
- artifact media type
application/vnd.oci.image.manifest.v1+json- config media type
application/vnd.cncf.flux.config.v1+json- content media type
application/vnd.cncf.flux.content.v1.tar+gzipPlease open an issue with them, they should be able to addvnd.cncf.fluxto their allow list.