X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;ds=sidebyside;f=modules%2Fmotd%2Ftemplates%2Fmotd.erb;h=592128b518fb40e124240877a2de29917a8c3ffb;hb=7f36c9ccbdaa846fc026b95c8ac0b53e818cfc08;hp=8622602296ecc949c3fcfb1ecd26899b932863c0;hpb=5275770968b17ca00ae43f19c92ffa825cda6f71;p=mirror%2Fdsa-puppet.git diff --git a/modules/motd/templates/motd.erb b/modules/motd/templates/motd.erb index 862260229..592128b51 100644 --- a/modules/motd/templates/motd.erb +++ b/modules/motd/templates/motd.erb @@ -1,4 +1,4 @@ -<% if @lsbdistcodename == 'wheezy' -%> +<% if @lsbmajdistrelease >= '7' -%> #!/bin/bash cat <= '7' + purp += "" + purp += "\tCurrently the master node is $(cat /var/lib/ganeti/ssconf_master_node).\n" end + #nodes = scope.lookupvar('::cluster_nodes').to_s.split.sort + #nodes.each do |node| + # purp += "\t" + node + "\n" + #end + #nodes.reject{|node| node.eql?(fqdn)}.each do |node| + # purp += "\t" + node + "\n" + # scope.lookupvar('site::allnodeinfo')[node]['ipHostNumber'].each do |ip| + # purp += "\t\t" + ip + "\n" + # end + #end end +if classes.include?("porterbox") + purp += "\nPlease clean up any schroots after you are done using them. Please also\n" + + "remove any build and source trees in your home directory once you no longer\n" + + "need them. Disk space on porter machines often is scarce. If it becomes\n" + + "necessary we will delete your entire home directory without warning, but this\n" + + "would really imply that you have been misusing resources. We prefer this\n" + + "not become necessary.\n" + + "\n *** Clean up after yourself! ***\n" +end + +if ninfo['not-bacula-client'] then + purp += "\n Note that this host is _NOT_ being backed up. If you care about your\n" + + " data, run your own backups.\n" +end + if scope.lookupvar('site::nodeinfo').has_key?('footer') purp += "\n" + wrap(scope.lookupvar('site::nodeinfo')['footer']) + "\n" end @@ -135,7 +161,7 @@ purp %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -<% if @lsbdistcodename == 'wheezy' -%> +<% if @lsbmajdistrelease >= '7' -%> EOD <% end -%> <%