cs-codex-dist-tests/MetricsPlugin/PrometheusContainerRecipe.cs

20 lines
578 B
C#
Raw Normal View History

2023-09-13 09:25:08 +00:00
using Core;
using KubernetesWorkflow;
2023-09-13 09:25:08 +00:00
namespace MetricsPlugin
{
public class PrometheusContainerRecipe : DefaultContainerRecipe
{
public override string AppName => "prometheus";
public override string Image => "codexstorage/dist-tests-prometheus:latest";
2023-09-13 09:25:08 +00:00
protected override void InitializeRecipe(StartupConfig startupConfig)
{
var config = startupConfig.Get<PrometheusStartupConfig>();
2023-09-13 09:25:08 +00:00
AddExposedPortAndVar("PROM_PORT");
AddEnvVar("PROM_CONFIG", config.PrometheusConfigBase64);
}
}
}