//
you're reading...
puppet

Creating a simple puppet manifest

This puppet manifest will create a group, a user, a directory and a file within the directory.

# vim /home/user/test_manifest.pp


group { 'user_test':
  ensure => 'present',
  gid    => '13000',
     }

user { 'user_test':
  ensure     => present,
  uid        => '13000',
  gid        => '13000',
  shell      => '/bin/bash',
  home       => '/home/user_test',
  password         => 'password',
  password_max_age => '99999',
  password_min_age => '0',
}

file { '/Puppet_test/directory':
    ensure => 'directory',
    owner  => 'user_test',
    group  => 'user_test',
    mode   => '0750',
  }

file { "/Puppet_test/directory/file":
        ensure => "present",
        owner => "user_test",
        group => "user_test",
        mode => "0644",
        content => "This is a test, puppet manifest"
}
Advertisements

About silvinux

I'm an IT freaky, that love to deploy (free software/ OpenSource) technologies in little projects at my home and this blog is a series of documents/manuals/guides that I've made through time to time.

Discussion

No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: