forked from NationTech/harmony
		
	fix: added routes to domain name for prometheus, grafana, alertmanageradded argo cd to the reporting after successfull build
This commit is contained in:
		
							parent
							
								
									49370af176
								
							
						
					
					
						commit
						19f87fdaf7
					
				| @ -55,7 +55,8 @@ impl<T: Topology + K8sclient + HelmCommand + Ingress> Interpret<T> for ArgoInter | |||||||
|         topology: &T, |         topology: &T, | ||||||
|     ) -> Result<Outcome, InterpretError> { |     ) -> Result<Outcome, InterpretError> { | ||||||
|         let k8s_client = topology.k8s_client().await?; |         let k8s_client = topology.k8s_client().await?; | ||||||
|         let domain = topology.get_domain("argo").await?; |         let svc = format!("argo-{}", self.score.namespace.clone()); | ||||||
|  |         let domain = topology.get_domain(&svc).await?; | ||||||
|         let helm_score = |         let helm_score = | ||||||
|             argo_helm_chart_score(&self.score.namespace, self.score.openshift, &domain); |             argo_helm_chart_score(&self.score.namespace, self.score.openshift, &domain); | ||||||
| 
 | 
 | ||||||
| @ -66,14 +67,17 @@ impl<T: Topology + K8sclient + HelmCommand + Ingress> Interpret<T> for ArgoInter | |||||||
|             .await |             .await | ||||||
|             .unwrap(); |             .unwrap(); | ||||||
| 
 | 
 | ||||||
|         Ok(Outcome::success(format!( |         Ok(Outcome::success_with_details( | ||||||
|             "ArgoCD installed with {} {}", |             format!( | ||||||
|  |                 "ArgoCD {} {}", | ||||||
|                 self.argo_apps.len(), |                 self.argo_apps.len(), | ||||||
|                 match self.argo_apps.len() { |                 match self.argo_apps.len() { | ||||||
|                     1 => "application", |                     1 => "application", | ||||||
|                     _ => "applications", |                     _ => "applications", | ||||||
|                 } |                 } | ||||||
|         ))) |             ), | ||||||
|  |             vec![format!("argo application: http://{}", domain)], | ||||||
|  |         )) | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     fn get_name(&self) -> InterpretName { |     fn get_name(&self) -> InterpretName { | ||||||
|  | |||||||
| @ -141,7 +141,10 @@ impl<T: Topology + K8sclient> Interpret<T> for K8sIngressInterpret { | |||||||
|                 InterpretStatus::SUCCESS => { |                 InterpretStatus::SUCCESS => { | ||||||
|                     let details = match &self.namespace { |                     let details = match &self.namespace { | ||||||
|                         Some(namespace) => { |                         Some(namespace) => { | ||||||
|                             vec![format!("{} ({namespace}): {}", self.service, self.host)] |                             vec![format!( | ||||||
|  |                                 "{} ({namespace}): http://{}", | ||||||
|  |                                 self.service, self.host | ||||||
|  |                             )] | ||||||
|                         } |                         } | ||||||
|                         None => vec![format!("{}: {}", self.service, self.host)], |                         None => vec![format!("{}: {}", self.service, self.host)], | ||||||
|                     }; |                     }; | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user