red-hat-storage / mcg-osd-deployer Goto Github PK
View Code? Open in Web Editor NEWA deployer for mcg-operator (NooBaa).
License: Apache License 2.0
A deployer for mcg-operator (NooBaa).
License: Apache License 2.0
Line 189 in 465834b
I think that using the external_labels
setting in prometheus configuration would fit very well with our requirements, (and less code is always better.) In any case your proposal is ok for me.
https://prometheus.io/docs/prometheus/latest/configuration/configuration/
# The labels to add to any time series or alerts when communicating with
# external systems (federation, remote storage, Alertmanager).
external_labels:
[ [<labelname>]: [<labelvalue>]
Originally posted by @jmolmo in #69 (comment)
Can we test this as well like so: https://github.com/red-hat-storage/ocs-osd-deployer/pull/240/files#diff-1d409d0b85193d4fa78899757bfc7c41ce41a06da0fb1f48d01d4cf7187ce654?
I have tried without success. Something weird in our test, the instance r of "ManagedMCGReconciler" is not the same that the one used "inside" r.reconcile. However i have verified that the modifications to "WriteRelabelConfigs" are applied successfully.
I have though to refactor completelly the test, but that will take some time, and this seems to be urgent.
I will ping you tomorrow to review the problem with you ( maybe i miss something :-)
Originally posted by @jmolmo in #75 (comment)
After reading through the code and result of make run
, I see Internals members of ManagedMCGReconciler.odfOperatorManagerconfigMap
are not initialized. I below function, r.odfOperatorManagerconfigMap.Data["ODF_SUBSCRIPTION_NAME"]
is accessed but did not find the place where it is initialized.
func (r *ManagedMCGReconciler) reconcileODFOperatorMgrConfig() error {
r.Log.Info("Reconciling odf-operator-manager-config ConfigMap")
_, err := ctrl.CreateOrUpdate(r.ctx, r.Client, r.odfOperatorManagerconfigMap, func() error {
r.odfOperatorManagerconfigMap.Data["ODF_SUBSCRIPTION_NAME"] = "odf-operator-stable-4.9-redhat-operators-openshift-marketplace"
r.odfOperatorManagerconfigMap.Data["NOOBAA_SUBSCRIPTION_STARTINGCSV"] = "mcg-operator.v4.9.2"
return nil
})
if err != nil {
return err
}
return nil
}
Do we require to init it ? like below ?
func (r *ManagedMCGReconciler) initReconciler(req ctrl.Request) {
r.managedMCG.Namespace = r.namespace
r.odfOperatorManagerconfigMap = &corev1.ConfigMap{}
+ r.odfOperatorManagerconfigMap.Data = make(map[string]string)
r.odfOperatorManagerconfigMap.Name = odfOperatorManagerconfigMapName
r.odfOperatorManagerconfigMap.Namespace = r.namespace
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.