Skip to content
Snippets Groups Projects
Commit 4db3a22f authored by Thomas Bellman's avatar Thomas Bellman
Browse files

Sort dsm.opt and dsm.sys based on resource title.

Use the tsmclient resource title to sort entries in dsm.opt and dsm.sys
instead of the symbolic server name.  This can be used to select the
default server, by making sure that resource's title is lexically after
all other tsmclient resources.
parent 3a31e650
No related branches found
No related tags found
No related merge requests found
...@@ -42,8 +42,11 @@ import "nsc-puppet-utils" ...@@ -42,8 +42,11 @@ import "nsc-puppet-utils"
* names), in which case dsm.sys and dsm.opt will contain all the * names), in which case dsm.sys and dsm.opt will contain all the
* declared servers with their respective configurations. Unconfiguring * declared servers with their respective configurations. Unconfiguring
* a server is done by just not declaring it in the manifests anymore. * a server is done by just not declaring it in the manifests anymore.
* There is however no way of declaring which of the servers should be *
* the default server. * The server entries in dsm.opt and dsm.sys are ordered lexically based
* on the tsmclient resource titles. This can be exploited to select
* the default server (the last one wins), by explicitly setting the
* name parameter.
* *
* The caller must provide a class named 'tsmclient::siteconfig' * The caller must provide a class named 'tsmclient::siteconfig'
* for configuration, defining the following class variables: * for configuration, defining the following class variables:
...@@ -204,9 +207,9 @@ define tsmclient($serveraddress, $nodename=$fqdn, ...@@ -204,9 +207,9 @@ define tsmclient($serveraddress, $nodename=$fqdn,
require => Package['TIVsm-BA'], notify => Service['dsmcad']; require => Package['TIVsm-BA'], notify => Service['dsmcad'];
} }
concat_part { concat_part {
"${tsmdir}/bin/dsm.opt/${tsm_servername}": "${tsmdir}/bin/dsm.opt/${title}":
content => template('tsmclient/dsm.opt.erb'); content => template('tsmclient/dsm.opt.erb');
"${tsmdir}/bin/dsm.sys/${tsm_servername}": "${tsmdir}/bin/dsm.sys/${title}":
content => template('tsmclient/dsm.sys.erb'); content => template('tsmclient/dsm.sys.erb');
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment