Bug 2092866 - Error while using Charts that use ConfigMap with the same repository name
Summary: Error while using Charts that use ConfigMap with the same repository name
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Special Resource Operator
Version: 4.11
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ---
: ---
Assignee: slovern
QA Contact: Constantin Vultur
Tomas 'Sheldon' Radej
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-06-02 12:19 UTC by Constantin Vultur
Modified: 2022-08-16 02:50 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Known Issue
Doc Text:
Cause: Using multiple charts (specialresource / specialresourcemodule) that specify the same repository name, causes error : /home/nonroot/.cache/special-resource-operator/helm/cache/ping-pong-0.0.1.tgz' does not appear to be a gzipped archive; got 'application/octet-stream'" Consequence: Conflict with chart names. Workaround (if any): configmaps repository names should be unique. Result: Using different repo names resolve the error.
Clone Of:
Environment:
Last Closed: 2022-08-16 02:50:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Constantin Vultur 2022-06-02 12:19:41 UTC
Description of problem:
Using multiple charts (specialresource / specialresourcemodule) that specify the same repository name, causes error :

/home/nonroot/.cache/special-resource-operator/helm/cache/ping-pong-0.0.1.tgz' does not appear to be a gzipped archive; got 'application/octet-stream'"

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. Change the repository name from : https://github.com/openshift/special-resource-operator/blob/master/charts/example/ping-pong-0.0.1/ping-pong.yaml#L11 to 'name: example'
2. Change the reposotury name from : https://github.com/openshift/special-resource-operator/blob/master/charts/example/simple-kmod-0.0.1/simple-kmod.yaml#L11 to 'name: example'
3. build helm package for both simple-kmod and ping-pong
4. create namespace and configmaps for simple-kmod and ping-pong
5. deploy the simple-kmod ( oc create -f )
6. deploy the ping-ping ( oc create -f )

Actual results:
ping-pong is failing to deploy because of this error:

{"level":"error","ts":1654171333.9798455,"logger":"controller.specialresource","msg":"Reconciler error","reconciler group":"sro.openshift.io","reconciler kind":"SpecialResource","name":"ping-pong","namespace":"","error":"failed to load helm chart ping-pong: file '/home/nonroot/.cache/special-resource-operator/helm/cache/ping-pong-0.0.1.tgz' does not appear to be a gzipped archive; got 'application/octet-stream'","stacktrace":"sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func2.2\n\t/workspace/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:227"}

More likely this is because of local caching of the configmaps in the operator


Expected results:
- handle the same helm repository name OR
- properly document that configmaps repository names should be unique, otherwise, the:
'/home/nonroot/.cache/special-resource-operator/helm/cache/ping-pong-0.0.1.tgz' does not appear to be a gzipped archive; got 'application/octet-stream'
 is seen


Additional info:


Note You need to log in before you can comment on or make changes to this bug.