From 9bbbb7120edfbf38230a4e2eb9f5007c44b3ccb8 Mon Sep 17 00:00:00 2001
From: matheushent <me@mtosta.dev>
Date: Wed, 15 Jan 2025 12:57:43 +0000
Subject: [PATCH] fix: set the `influx-dsn` configuration in the
 **jobbergate-agent** snap.

This commit modifies the **democluster** **user-data** file in order to
set the configuration `influx-dsn` for the **jobbergate-agent** snap.
This is necessary so the job metric integration is properly started
by the agent.
---
 public-scripts/deploy-democluster.sh | 1 +
 1 file changed, 1 insertion(+)

diff --git a/public-scripts/deploy-democluster.sh b/public-scripts/deploy-democluster.sh
index 95599da..672460b 100755
--- a/public-scripts/deploy-democluster.sh
+++ b/public-scripts/deploy-democluster.sh
@@ -108,6 +108,7 @@ runcmd:
   - snap set jobbergate-agent oidc-client-secret=$CLIENT_SECRET
   - snap set jobbergate-agent task-jobs-interval-seconds=30
   - snap set jobbergate-agent x-slurm-user-name=root
+  - snap set jobbergate-agent influx-dsn=influxdb://slurm:rats@localhost:8086/slurm-job-metrics
   - snap start vantage-agent.start
   - snap start jobbergate-agent.start
 EOF