标签:ansible
用ansible实现较复杂的shell命令:
1.
ansible -i /tmp/batchtwo all -m shell -a "for i in \`ps aux |grep proc_nodemanager | grep -v grep | awk ‘{print \$2}‘\`; do echo \$i ; done" -k -u root
本文出自 “Linux和网络” 博客,谢绝转载!
标签:ansible
原文地址:http://haohaozhang.blog.51cto.com/9176600/1619687