{% set Champ = grains['host'] %} {% if Champ.startswith('CT-deb-elastic') %} Installation du packages ElasticSearch OpenJDK: pkg.installed: - name: {{ pillar['installjdk'] }} Installation du packages ElasticSearch https-transport: pkg.installed: - name: {{ pillar['installtransport'] }} Installation du package CURL: pkg.installed: - name: curl Test de copie de fichier: file.managed: - name: /tmp/elastic-install.sh - source: salt://elastic/elastic_install.sh Installons: cmd.script: - source: salt://elastic/elastic_install.sh - user: root - group: root - shell: /bin/bash {% endif %}