I need to automate something as part of post processing in a script . Each project is identified by a 3 letter string which is part of hostname and based on hostname I need to copy a particular file to that machine from my distribution .
here are hostnames
pprdifeap01.corp.host.net (where ife is the string I need ) and if so I copy /opt/distribution/ife.cfg to /usr/local/jboss/bin
pprdyamap05.corp.host.net ....if "yam" then cp /opt/distribution/yam.cfg /usr/local/jboss/bin
I have around 10 projects or so with different strings with different config files.
thanks