What shall I try ?
I don’t understand how to add in the environment th eexecution of the .profile on the remote server ?
I am a newby with ansible, I have not a clue to do so.
What shall I try ?
I don't understand how to add in the environment th eexecution of the
.profile on the remote server ?
I am a newby with ansible, I have not a clue to do so.
You can write a shell script that consists of
- the setting of the environment variable
- the desired action
OK thank you but this set the environment variable on the server where the playbook is run, I need the environment variables set on the target server whe running shells because the .profile is not run when connected with ssh.
So I cannot use your bypass solution
Thank you,
the bypass solution I am finally using is to copy the dispatcher.sh into a new file, then with the help of lineinfile, I insert after the #!/bin/ksh first line the call of the .profile and when it is done I do remove this temporary file: