You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
执行后发现未有返回结果
后来我将结果打印返回为空 ,后台打印
[WARNING]: No inventory was parsed, only implicit localhost is available
[WARNING]: Could not match supplied host pattern, ignoring: all
[WARNING]: Could not match supplied host pattern, ignoring: test
类似这样的 输出
后来我实例化了 MyInventory这个类 并执行了dynamic_inventory方法返回依旧是空
最终我打印了resource即type发现为tuple并不是dict也不是list 经过查看是返回了两个值
Activity
zzjackaa commentedon Jul 8, 2020
还有建议 执行celery打开调试 root@big02:/data/Ops-master# export C_FORCE_ROOT="true"
root@big02:/data/Ops-master# C_FAKEFORK=1 sh -x /etc/init.d/celeryd start
不然可能会发现不到错误 并且日志后台也不会有输出
wodezz commentedon Dec 16, 2021
已经将ans_playbook_websocket.py下的
resource = GenResource().gen_group_dict(group_ids)
改为
resource ,group_name= GenResource().gen_group_dict(group_ids)
但是执行后还是没东西

还有就是yml到底是要怎么写才可以,我写了个测试的
tasks:
copy: src=/root/initial-setup-ks.cfg dest=/root/initial-setup-ks.cfg
wodezz commentedon Dec 16, 2021
已经将ans_playbook_websocket.py下的
resource = GenResource().gen_group_dict(group_ids)
改为
resource ,group_name= GenResource().gen_group_dict(group_ids)
但是执行后还是没东西

还有就是yml到底是要怎么写才可以,我写了个测试的
tasks:
copy: src=/root/initial-setup-ks.cfg dest=/root/initial-setup-ks.cfg