2
0
mirror of synced 2025-01-12 17:44:08 +00:00
cs-codex-dist-tests/ProjectPlugins/MetricsPlugin/PrometheusContainerRecipe.cs

21 lines
631 B
C#
Raw Normal View History

2023-09-13 16:06:05 +02:00
using KubernetesWorkflow;
2023-09-13 11:25:08 +02:00
namespace MetricsPlugin
{
2023-09-13 16:06:05 +02:00
public class PrometheusContainerRecipe : ContainerRecipeFactory
2023-09-13 11:25:08 +02:00
{
public override string AppName => "prometheus";
public override string Image => "codexstorage/dist-tests-prometheus:latest";
2023-10-19 11:12:08 +02:00
public const string PortTag = "prometheus_port_tag";
2023-09-13 16:06:05 +02:00
protected override void Initialize(StartupConfig startupConfig)
2023-09-13 11:25:08 +02:00
{
var config = startupConfig.Get<PrometheusStartupConfig>();
2023-10-19 11:12:08 +02:00
AddExposedPortAndVar("PROM_PORT", PortTag);
2023-09-13 11:25:08 +02:00
AddEnvVar("PROM_CONFIG", config.PrometheusConfigBase64);
}
}
}