-
Notifications
You must be signed in to change notification settings - Fork 177
Open
Description
Expected Behavior
Labels defined in the /etc/sensu/agent.yml
should appear in the Sensu UI for the respective agent.
Current Behavior
The Sensu UI does not display the labels defined in the agent.yml
file. When the Sensu agent is started with the --label
flag, labels appear in the UI, but not when they're configured directly in the agent.yml
.
Possible Solution
A potential cause might be the Sensu UI not reloading or recognizing updates made to the agent.yml
configuration file.
Steps to Reproduce (for bugs)
- Configure labels in
/etc/sensu/agent.yml
. - Restart sensu-agent using
systemctl
. - Observe that labels do not appear in the Sensu UI.
- Stop the agent and restart with the
--labels
flag, noting that labels now appear in the UI.
Context
This issue is causing difficulties in dynamically managing labels through configuration management tools like Ansible. My objective is to manage agent configuration solely through Ansible without needing additional flags at startup.
Your Environment
- Sensu version used: sensu-agent version 6.11.0+ee
- Installation method: Ansible setup based on the documentation provided at https://docs.steampunk.si/sensu/quickstart-sensu-go-6.html
- Operating System and version: Ubuntu 20.04
My Setup
sudo cat /etc/sensu/agent.yml
---
#
# Managed by Ansible - do NOT edit this file manually!
#
##
# Sensu agent configuration
##
backend-url:
- ws://<sensu-backend>:8081
keepalive-interval: 5
keepalive-timeout: 10
labels:
node_tag: mix-node-0
name: my-agent
Ansible
- name: Install, configure and run Sensu agents
hosts: agents
become: true
tasks:
- name: Install agent
include_role:
name: sensu.sensu_go.agent
vars:
agent_config:
name: my-agent
keepalive-interval: 5
keepalive-timeout: 10
labels:
node_tag: "{{ node_tag }}"
Metadata
Metadata
Assignees
Labels
No labels