# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
export JAVA_HOME=/xxx/xxx/xxx/jdk1.7.0_21
PATH=\$PATH:\$HOME/bin:\$JAVA_HOME/bin
export HOST_NAME=`hostname -s` " > .bash_profile
How do I solve this problem from playbook. I need the task to copy the .bash_profile reflecting the hostname of the server.
It has to execute the `hostname -s` .
I can template and copy, but cannot I need it to do the command substitution.
Thanks,
Darup.
currently,I am solving this problem making it as a script and using