使用Puppet用户资源创build多个用户
我在下面用puppet user资源写下面的代码片段来创buildunix用户。 node 'node2.example.com','node3.example.com'{ user { 'askar': ensure => 'present', managehome => 'true', comment => 'man Home', home => '/home/askar', shell => '/bin/bash', expiry => '2016-03-22', password => '$1$cs1j/tD$4Q2Ocr0pulyNTUx/', password_min_age => '30', password_max_age => '60', } exec { 'chage': path => '/usr/bin/', command => 'chage -d 0 askar', } } 它对我来说工作正常,但对我来说,我需要创build10到20个用户。 我如何重用上述代码段来创build10个用户。 我是puppet新手,所以指针会有很大的帮助。