ajout de linterface hermes + route

This commit is contained in:
alkatrazz 2026-05-12 18:01:50 +02:00
parent 5615ead566
commit 572e949ce4
5 changed files with 60 additions and 1 deletions

View file

@ -10,3 +10,7 @@ hermes_context_length: 65536
hermes_gateway_port: 8080
hermes_gateway_host: "0.0.0.0"
# Dashboard web
hermes_dashboard_port: 9119
hermes_dashboard_allowed_ip: "192.168.1.10"

View file

@ -7,3 +7,8 @@
ansible.builtin.systemd:
name: hermes-agent
state: restarted
- name: Restart hermes-dashboard
ansible.builtin.systemd:
name: hermes-dashboard
state: restarted

View file

@ -132,6 +132,24 @@
daemon_reload: true
state: started
# --- Dashboard systemd ---
- name: Deploy hermes-dashboard systemd service
ansible.builtin.template:
src: hermes-dashboard.service.j2
dest: /etc/systemd/system/hermes-dashboard.service
mode: '0644'
notify:
- Reload systemd
- Restart hermes-dashboard
- name: Enable and start hermes-dashboard
ansible.builtin.systemd:
name: hermes-dashboard
enabled: true
daemon_reload: true
state: started
# --- Wrapper global ---
- name: Deploy hermes global wrapper (/usr/local/bin/hermes)

View file

@ -0,0 +1,24 @@
[Unit]
Description=Hermes Agent Web Dashboard
After=hermes-agent.service
Wants=hermes-agent.service
[Service]
User={{ hermes_user }}
Group={{ hermes_user }}
Environment=HOME={{ hermes_home }}
Environment=HERMES_HOME={{ hermes_data_dir }}
Environment=PATH={{ hermes_data_dir }}/node/bin:{{ hermes_data_dir }}/hermes-agent/venv/bin:/usr/local/bin:/usr/bin:/bin
ExecStart={{ hermes_home }}/.local/bin/hermes dashboard --no-open --tui --insecure --host {{ ansible_host }} --port {{ hermes_dashboard_port }}
Restart=on-failure
RestartSec=10s
StandardOutput=journal
StandardError=journal
SyslogIdentifier=hermes-dashboard
[Install]
WantedBy=multi-user.target