thanks for your quick replay, unfortunately, it works the same like before.
TASK: [vas | vas installing...]
***********************************************
failed: [cnshget04.xxx] => {"cmd": "/opt/quest/bin/vastool -u ''
task file:
shell: >
"{{vastool_binary}}" -u '{{username}}'
在 2016年3月28日星期一 UTC+8下午11:09:38,Brian Coca写道:
>
> @ is special in bash, use single quotes to avoid interpolation `-u
> '{{username}}'`
>
> On Mon, Mar 28, 2016 at 6:00 AM, Cai Elvis <[email protected] <javascript:>
> > wrote:
>
>> Hi guys
>>
>> i met a wield issue in ansible when using variable including '@' sign, if
>> my variable including @, it will turn to empty totally and the debug
>> infomation is hello world, when i remove @ sign, the result is normal, is
>> there anyone could help? thanks in advance! :-)
>>
>> TASK: [vas | debug username]
>> **************************************************
>>
>> ok: [cnshget04.xxx] => {
>> "msg": "Hello world!"
>>
>> TASK: [vas | vas installing...]
>> ***********************************************
>> failed: [cnshget04.xxx] => {"cmd": "/opt/quest/bin/vastool -u ''
>>
>> task file:
>> - name: vas installing...
>> shell: >
>> "{{vastool_binary}}" -u "{{username}}"
>>
>> default file:
>> -sh-4.1$ cat defaults/main.yml | grep username
>> username: 'username'
>>
>> my playbook:
>> - role: vas
>> username: [email protected] <javascript:>
>>
>> my ansible version is 1.9.4
>>
>>
>>
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Ansible Project" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected] <javascript:>.
>> To post to this group, send email to [email protected]
>> <javascript:>.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/ansible-project/7b1de730-7594-4f82-aa73-813d0830bafe%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/ansible-project/7b1de730-7594-4f82-aa73-813d0830bafe%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> ----------
> Brian Coca
>
--
You received this message because you are subscribed to the Google Groups
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/c6928b65-c879-4567-9f6f-5a032dcedb69%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.