-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(insights): optionally deploy a proxy for Insights #670
Conversation
Signed-off-by: Elliott Baron <[email protected]>
Looks like it makes sense from a cursory reading - just checking that it lines up with my rough prototyping work. |
/build_test |
I see errors like this in the log:
but the Insights Proxy Deployment and Service still get created, so maybe they're harmless. I tried this both with an
When I do |
The "object has been modified" errors are indeed harmless. This can happen from things like Kubernetes modifying a field in the deployment in between us doing a get and update. The changes are retried on the next iteration of the reconcile loop. For the second problem, I may have broken the controller watches. I'll take a look. |
Fixed now. The controller watches weren't handling the empty |
* feat(insights): mount Insights token in Cryostat container Signed-off-by: Elliott Baron <[email protected]> * Use 0440 mode for mounted token * Envtest based tests for controller watch changes * Fix hardcoded OpenShift module version * clean up test * Create HTTP proxy for communicating with Insights * Handle deletion case, add tests * Set INSIGHTS_PROXY, additional testing * cleanup * Convert filter test to unit test * Move setup to its own test file * cleanup * Add resource requirements and more tests * Fix license * Check the rest of the deployment too * Update log message * Add Bearer to Authentication header * Fix AllNamespaces install mode handling * Regenerate bundle --------- Signed-off-by: Elliott Baron <[email protected]> (cherry picked from commit d719e43) # Conflicts: # bundle/manifests/cryostat-operator.clusterserviceversion.yaml
#673) * feat(insights): optionally deploy a proxy for Insights (#670) * feat(insights): mount Insights token in Cryostat container Signed-off-by: Elliott Baron <[email protected]> * Use 0440 mode for mounted token * Envtest based tests for controller watch changes * Fix hardcoded OpenShift module version * clean up test * Create HTTP proxy for communicating with Insights * Handle deletion case, add tests * Set INSIGHTS_PROXY, additional testing * cleanup * Convert filter test to unit test * Move setup to its own test file * cleanup * Add resource requirements and more tests * Fix license * Check the rest of the deployment too * Update log message * Add Bearer to Authentication header * Fix AllNamespaces install mode handling * Regenerate bundle --------- Signed-off-by: Elliott Baron <[email protected]> (cherry picked from commit d719e43) # Conflicts: # bundle/manifests/cryostat-operator.clusterserviceversion.yaml * Fix conflicts --------- Co-authored-by: Elliott Baron <[email protected]>
Welcome to Cryostat! 👋
Before contributing, make sure you have:
main
branch[chore, ci, docs, feat, fix, test]
git commit -S -m "YOUR_COMMIT_MESSAGE"
Related to: https://github.com/cryostatio/cryostat/issues/1763
Description of the change:
This change is expected to do nothing unless the environment variable
INSIGHTS_ENABLED
is set to true. If the variable is set to true, then the operator takes several actions:cloud.openshift.com
authentication token from the global pull secret.INSIGHTS_PROXY
environment variable.Motivation for the change:
Red Hat customers will automatically be able to integrate Red Hat Insights with their workloads by using the Cryostat Operator, Cryostat, and Cryostat Agent, from the downstream Red Hat build of Cryostat.
How to manually test:
make oci-build SKIP_TESTS=true ENABLE_INSIGHTS=true OPERATOR_IMG=quay.io/ebaron/cryostat-operator:insights-test-11
make deploy ENABLE_INSIGHTS=true OPERATOR_IMG=quay.io/ebaron/cryostat-operator:insights-test-11
make cryostat_cr
INSIGHTS_PROXY
set tohttp://insights-proxy.cryostat-operator-system.svc.cluster.local
.ENABLE_INSIGHTS=true
, none of the objects from step 3 should be present, and theINSIGHTS_PROXY
environment variable should not be set.