Writing the Puppet code