{% extends 'base.html' %} {% block title %}Settings{% endblock %} {% block content %}

Settings

{% if saved %}
Section "{{ saved }}" sauvegardee.
{% endif %} {% macro section_header(key, title, badge_text, badge_class, extra="") %} {% endmacro %}
{% if visible.qualys %}
{{ section_header("qualys", "Qualys API", "Connecte", "badge-green", q_tags|string + " tags / " + q_assets|string + " assets / " + q_linked|string + " lies") }}
{% if editable.qualys %}{% endif %}
{% endif %} {% if visible.ssh_key %}
{{ section_header("ssh_key", "SSH Cle privee", "ssh_key", "badge-green") }}

Surchargeable par serveur (ssh_user, ssh_port dans la fiche serveur).

{% if editable.ssh_key %}{% endif %}
{% endif %} {% if visible.ssh_pwd %}
{{ section_header("ssh_pwd", "SSH Password", "ssh_pwd", "badge-yellow") }}

Pour les environnements recette sans cle SSH. Chaque operateur peut configurer son propre compte.

{% if editable.ssh_pwd %}{% endif %}
{% endif %} {% if visible.ssh_psmp %}
{{ section_header("ssh_psmp", "SSH PSMP — CyberArk", "ssh_psmp", "badge-yellow") }}

Auth keyboard-interactive. Chaque operateur configure son propre compte CyberArk. MDP saisi en session.

{% if editable.ssh_psmp %}{% endif %}
{% endif %} {% if visible.rdp_psm %}
{{ section_header("rdp_psm", "RDP PSM — CyberArk", "rdp_psm", "badge-blue") }}

Connexion RDP via token PVWA API. Production Windows uniquement.

{% if editable.rdp_psm %}{% endif %}
{% endif %} {% if visible.vsphere %}
{% if editable.vsphere %}

Credentials vSphere (communs)

{% endif %}

vCenters enregistres

{% if editable.vsphere %}{% endif %} {% for vc in vcenters %} {% if editable.vsphere %} {% endif %} {% endfor %}
Nom Endpoint Datacenter Description Responsable ActifAction
{{ vc.name }} {{ vc.endpoint }} {{ vc.datacenter or '-' }} {{ vc.description or '-' }} {{ vc.responsable or '-' }} {{ 'Oui' if vc.is_active else 'Non' }} {% if vc.is_active %}
{% endif %}
{% if editable.vsphere %}

Ajouter un vCenter

{% endif %}
{% endif %} {% if visible.vsphere %}

Deux modes pris en charge : SharePoint (PatchCenter écrit un fichier .txt dans un dossier OneDrive sync, un Workflow Power Automate côté SharePoint poste sur Teams — pas d'OAuth) ; Webhook (POST direct, OAuth Entra ID requis, futur). Le routage serveur → canal est pris en charge par les règles.

Canaux enregistrés

{% if editable.vsphere %}{% endif %} {% for tc in teams_channels %} {% if editable.vsphere %} {% endif %} {% else %} {% endfor %}
Nom Mode SP route / Webhook Défaut Reboot DM dyn. ActifActions
{{ tc.name }} {{ tc.mode }} {% if tc.mode == 'sharepoint' %}{{ tc.sp_route or '(non défini)' }} {% else %}{{ (tc.webhook_url or '')[:60] }}{% if tc.webhook_url and tc.webhook_url|length > 60 %}…{% endif %} {% endif %} {{ 'Oui' if tc.is_default else '-' }} {{ 'Oui' if tc.is_reboot_channel else '-' }} {{ 'Oui' if tc.is_dynamic_dm else '-' }} {{ 'Oui' if tc.is_active else 'Non' }}
Aucun canal Teams configuré.
{% if editable.vsphere %}

Ajouter un canal Teams

{% endif %}

Règles de routage

Les règles sont évaluées par ordre de priorité croissante (10, 20, 30…). La première règle dont toutes les conditions actives matchent décide du canal. Conditions vides = pas filtré. Pour reboot, le canal flaggé "Reboot" gagne avant toute règle.

{% if editable.vsphere %}{% endif %} {% for tr in teams_rules %} {% if editable.vsphere %} {% endif %} {% else %} {% endfor %}
Prio Nom Match → Canal ActifActions
{{ tr.priority }} {{ tr.name }} {% if tr.responsable_name %}resp: {{ tr.responsable_name }}{% endif %} {% if tr.match_application_domain %}domain~{{ tr.match_application_domain }}{% endif %} {% if tr.match_env_in %}env∈{{ tr.match_env_in|join(',') }}{% endif %} {% if tr.match_msg_type_in %}msg∈{{ tr.match_msg_type_in|join(',') }}{% endif %} {% if tr.match_hostname_pattern %}host~{{ tr.match_hostname_pattern }}{% endif %} {{ tr.channel_name or '(canal supprimé)' }} {{ 'Oui' if tr.is_active else 'Non' }}
Aucune règle. Sans règles, seul le canal "défaut" sera utilisé.
{% if editable.vsphere %}
Ajouter une règle
{% endif %}
{% endif %} {% if visible.vsphere %}

Les clusters permettent de patcher plusieurs serveurs liés (ex : DB master + slaves, HAProxy + backends) avec un ordre de redémarrage. Le champ cluster_order sur chaque serveur fixe la séquence (1 = premier patché). Stratégie sequential = un par un (recommandé) ou parallel = tous en même temps.

Clusters enregistrés

{% if editable.vsphere %}{% endif %} {% for sc in server_clusters %} {% if editable.vsphere %} {% endif %} {% else %} {% endfor %}
Nom Description Stratégie # Serveurs ActifActions
{{ sc.name }} {{ sc.description or '-' }} {{ sc.reboot_strategy }} {{ sc.server_count }} {{ 'Oui' if sc.is_active else 'Non' }}
Aucun cluster configuré.
{% if editable.vsphere %}

Ajouter un cluster

{% endif %}
{% endif %} {% if visible.security %}
{{ section_header("security", "Sécurité", "Réseau", "badge-red") }}

Réseaux autorisés (nginx ACL)

{% if editable.security %}{% endif %} {% for n in allowed_nets %} {% if editable.security %} {% endif %} {% endfor %}
CIDR Description ActifActions
{{ n.cidr }} {{ n.description or '-' }} {{ 'Oui' if n.is_active else 'Non' }}
{% if editable.security %}
{% endif %}

Le fichier /etc/nginx/patchcenter_acl.conf est régénéré automatiquement à chaque modification. Nginx est rechargé.

Paramètres

{% if editable.security %}{% endif %}
{% endif %} {% if visible.splunk %}
{{ section_header("splunk", "Splunk — Remote Log", "HEC", "badge-yellow") }}

Envoie les evenements de patching vers Splunk via HEC.

{% if editable.splunk %}{% endif %}
{% endif %} {% if visible.teams %}
{{ section_header("teams", "Teams — Notifications", "Webhook + SharePoint", "badge-blue") }}

Canal Teams (Webhook direct)

Conversation groupe (SharePoint + Power Automate)

Power Automate : depose JSON sur SharePoint → lit + poste dans la conversation → supprime.

{% if editable.teams %}{% endif %}
{% endif %} {% if visible.itop %}
{% for key, label, is_secret in sections.itop %}
{% endfor %}
- Import serveurs + metadata
- Sync responsables / referents
- Lien applications / clusters
- Enrichissement domaine / environnement
{% if editable.itop %}{% endif %}
{% endif %} {% if visible.itop_contacts %}
{% for key, label, is_secret in sections.itop_contacts %}
{% endfor %}
Seuls les contacts appartenant à ces teams iTop seront synchronisés dans PatchCenter. Si vide, défaut : SecOps, iPOP, Externe, DSI, Admin DSI.
{% if editable.itop_contacts %}{% endif %}
{% endif %} {% if visible.ldap %}
{% for key, label, is_secret in sections.ldap %}
{% endfor %}
Une fois configuré et activé, le choix Local / LDAP apparaîtra sur la page de connexion. Les users peuvent aussi être forcés en LDAP via le champ "Auth" dans /users.
{% if editable.ldap %}{% endif %}
{% endif %}
{% endblock %}