How to change username of installed files after RPM installation using puppet?

asked 2018-02-26 04:10:11 -0500

I'm new to puppet, I need to build a RPM for set of libraries in such a way that i build and compile it in DEV server and this RPM need to be installed in other Server also like QA,PROD,UAT and these servers has different user names, so i need to build my RPM to contain and pick username for respective server during installation, can this be achieved using the chown,chgrp in the puppet script? Something like this

exec {"chown newuser:newgroup /directory1/directory2/; chown newuser:newgroup /directory3/directory4/file name.bsh"; }

edit retag flag offensive close merge delete