Skip to content

Commit

Permalink
Merge branch 'branches/rudder/8.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
fanf committed Feb 29, 2024
2 parents e8a3bde + b11efa6 commit ab949af
Show file tree
Hide file tree
Showing 3 changed files with 80 additions and 69 deletions.
9 changes: 0 additions & 9 deletions change-validation/README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,6 @@ is optional and can be disabled at any time without any problem, besides risking
image::docs/images/Enabling.png[]


== Rudder compatibility and breaking changes

=== Version 5.0-1.1 needs Rudder 5.0.1 or above

The problem was that on some condition, the change request was not saved in the correct data back-end: it was using the Rudder one in place of the plugin one.

- Rudder ticket: https://issues.rudder.io/issues/13609
- Plugin ticket: https://issues.rudder.io/issues/13630


== What is a Change request ?

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,66 +123,65 @@ <h3 class="page-title" style="margin-top: 0;">Change validation status</h3>
</div>
</div>
</div>

<div>
<h3 class="page-title">Configure email notification</h3>
<div class="section-with-doc">
<div class="section-left">
<p>You can modify the email's template of each steps here: </p>
<ul class="clipboard-list">
<li>
<span>/var/rudder/plugins/change-validation/validation-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/validation-mail.template"
data-bs-toggle='tooltip' data-bs-placement='bottom' data-bs-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
<li>
<span>/var/rudder/plugins/change-validation/deployment-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/deployment-mail.template"
data-bs-toggle='tooltip' data-bs-placement='bottom' data-bs-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
<li>
<span>/var/rudder/plugins/change-validation/cancelled-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/cancelled-mail.template"
data-bs-toggle='tooltip' data-bs-placement='bottom' data-bs-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
<li>
<span>/var/rudder/plugins/change-validation/deployed-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/deployed-mail.template"
data-bs-toggle='tooltip' data-bs-placement='bottom' data-bs-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
</ul>
</div>
<div class="section-right">
<div class="doc doc-info">
<div class="marker">
<span class="fa fa-info-circle"></span>
</div>
<p>
By default, email notifications are disabled. To enable them, make sure that the
<b>smtp.hostServer</b> parameter is
not left empty in the configuration file:
<b>/opt/rudder/etc/plugins/change-validation.conf</b>
</p>
</div>
</div>
</div>
</div>
<div>
<h3 class="page-title">Configure email notification</h3>
<div class="section-with-doc">
<div class="section-left">
<p>You can modify the email's template of each steps here: </p>
<ul class="clipboard-list">
<li>
<span>/var/rudder/plugins/change-validation/validation-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/validation-mail.template"
data-toggle='tooltip' data-placement='bottom' data-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
<li>
<span>/var/rudder/plugins/change-validation/deployment-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/deployment-mail.template"
data-toggle='tooltip' data-placement='bottom' data-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
<li>
<span>/var/rudder/plugins/change-validation/cancelled-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/cancelled-mail.template"
data-toggle='tooltip' data-placement='bottom' data-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
<li>
<span>/var/rudder/plugins/change-validation/deployed-mail.template</span>
<a class="btn-goto btn-clipboard"
data-clipboard-text="/var/rudder/plugins/change-validation/deployed-mail.template"
data-toggle='tooltip' data-placement='bottom' data-container="html"
title="Copy to clipboard">
<i class="far fa-clipboard"></i>
</a>
</li>
</ul>
</div>
<div class="section-right">
<div class="doc doc-info">
<div class="marker">
<span class="fa fa-info-circle"></span>
</div>
<p>
By default, email notifications are disabled. To enable them, make sure that the
<b>smtp.hostServer</b> parameter is
not left empty in the configuration file:
<b>/opt/rudder/etc/plugins/change-validation.conf</b>
</p>
</div>
</div>
</div>
</div>

<div>
<h3 class="page-title">Configure change request triggers</h3>
Expand Down
21 changes: 21 additions & 0 deletions glpi/etc/hooks.d/node-post-deletion/20-clean-inventories
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/bin/sh

# Hooks parameter are passed by environment variable:
#
# - RUDDER_NODE_ID: the nodeId
# - RUDDER_NODE_HOSTNAME: the node fully qualified hostname
# - RUDDER_NODE_POLICY_SERVER_ID: the node policy server id
# - RUDDER_AGENT_TYPE : agent type ("cfengine-community" or "dsc")
# - RUDDER_POLICIES_DIRECTORY_CURRENT: the full path of the base directory containing policies for that node
# - RUDDER_POLICIES_DIRECTORY_NEW: the full path of the base directory containing next policies for that node (during a generation)
# - RUDDER_POLICIES_DIRECTORY_ARCHIVE: the full path of the base directory containing previous policies for that node
# - RUDDER_NODE_KIND: node kind: root, relay or node


# Errors code on hooks are interpreted as follow:
# - 0 : success, no log (apart if debug one) , continue to next hook
# - 1-31 : error , error log in /var/log/rudder/webapp/, stop processing
# - 32-63 : warning, warning log in /var/log/rudder/webapp/, continue to next hook
# - 64-255: reserved for future use case. Behavior may change without notice.

rm -f /var/rudder/inventories/received/${RUDDER_NODE_HOSTNAME}-${RUDDER_NODE_ID}.ocs*

0 comments on commit ab949af

Please sign in to comment.