Skip to content

Instantly share code, notes, and snippets.

@jbarber
Created May 31, 2011 14:34
Show Gist options
  • Save jbarber/1000597 to your computer and use it in GitHub Desktop.
Save jbarber/1000597 to your computer and use it in GitHub Desktop.
XSLT for adding two-node configuration to RHCS cluster.conf
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:template match="@*|node()">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
<xsl:template match="cluster">
<xsl:copy>
<cman expected_votes="1" two_node="1"/>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
<xsl:template match="clusternode">
<xsl:copy>
<multicast addr="239.0.0.10" interface="eth0"/>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
</xsl:stylesheet>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment