Bug 1874754
Summary: | [downstream helm-operator] The pods of the CR is crashing(Permission denied) | ||
---|---|---|---|
Product: | OpenShift Container Platform | Reporter: | Jian Zhang <jiazha> |
Component: | Operator SDK | Assignee: | Alex Dellapenta <adellape> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Jian Zhang <jiazha> |
Severity: | medium | Docs Contact: | |
Priority: | unspecified | ||
Version: | 4.6 | CC: | aos-bugs, jesusr |
Target Milestone: | --- | Keywords: | UpcomingSprint |
Target Release: | 4.6.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Known Issue | |
Doc Text: |
Cause: Building and running a Helm-based operator that uses the default boilerplate nginx chart (by running operator-sdk new without the --helm-chart flag)
Consequence: The example chart fails to deploy cleanly on OpenShift (it works fine on upstream Kubernetes)
Workaround (if any): Use the --helm-chart flag to provide a helm chart that deploys cleanly on OpenShift
Result:
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 2020-12-14 17:09:22 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Jian Zhang
2020-09-02 07:32:12 UTC
This appears to be an issue with the operand image, not the operator image. The default chart that is scaffolded if --helm-chart is not provided comes from the upstream helm project's boilerplate chart and is meant to be modified by the helm chart / helm-operator developer. It seems the `nginx` image is not natively compatible with OpenShift? Changing severity to medium since this is not a bug with the helm-operator base image, and potentially not a bug at all, depending on whether it's considered a bug that an example boilerplate chart scaffolded by the SDK is not compatible with OpenShift. Since this issue only occurs with the boilerplate example chart provided by Helm (and only on OpenShift) and is not related to the Helm operator base image, I think we should document this as a known issue with OpenShift. This should not affect any production usage of the helm-operator because the sample chart is extremely simple and provides no real-world functionality. Add the `--helm-chart` flag when running the helm-operator. LGTM, verify it. [root@preserve-olm-env nginx-operator]# ./helm-operator run -- --helm-chart {"level":"info","ts":1600161079.4351165,"logger":"cmd","msg":"Go Version: go1.14"} {"level":"info","ts":1600161079.4351988,"logger":"cmd","msg":"Go OS/Arch: linux/amd64"} {"level":"info","ts":1600161079.4352088,"logger":"cmd","msg":"Version of operator-sdk: v0.19.0"} {"level":"info","ts":1600161079.4377782,"logger":"cmd","msg":"WATCH_NAMESPACE environment variable not set. Watching all namespaces.","Namespace":""} I0915 05:11:20.980035 31902 request.go:621] Throttling request took 1.049494513s, request: GET:https://api.min-shared0914.qe.devcluster.openshift.com:6443/apis/migration.k8s.io/v1alpha1?timeout=32s {"level":"info","ts":1600161082.3129342,"logger":"controller-runtime.metrics","msg":"metrics server is starting to listen","addr":"0.0.0.0:8383"} {"level":"info","ts":1600161082.3139274,"logger":"helm.controller","msg":"Watching resource","apiVersion":"example.com/v1alpha1","kind":"Nginx","namespace":"","reconcilePeriod":"1m0s"} {"level":"info","ts":1600161082.3139641,"logger":"leader","msg":"Trying to become the leader."} {"level":"info","ts":1600161082.313998,"logger":"leader","msg":"Skipping leader election; not running in a cluster."} {"level":"info","ts":1600161082.3140197,"logger":"cmd","msg":"Could not generate and serve custom resource metrics","Namespace":"","error":"WATCH_NAMESPACE must be set"} ... [root@preserve-olm-env nginx-operator]# oc create -f deploy/crds/example.com_v1alpha1_nginx_cr.yaml nginx.example.com/example-nginx created [root@preserve-olm-env nginx-operator]# oc get nginx -A NAMESPACE NAME AGE default example-nginx 10s [root@preserve-olm-env nginx-operator]# oc get pods NAME READY STATUS RESTARTS AGE example-nginx-7df4447d79-qhvrn 1/1 Running 0 86s scorecard-test-rvgn 0/1 Completed 0 22h Staged 4.6 doc for the merged content available here: https://docs.openshift.com/container-platform/4.6/release_notes/ocp-4-6-release-notes.html#ocp-4-6-known-issues |