Running Python script via ansible

后端 未结 2 1059
礼貌的吻别
礼貌的吻别 2021-01-01 10:29

I\'m trying to run a python script from an ansible script. I would think this would be an easy thing to do, but I can\'t figure it out. I\'ve got a project structure like th

2条回答
  •  孤独总比滥情好
    2021-01-01 11:08

    try to use script directive, it works for me

    my main.yml

    ---
    - name: execute install script
      script: get-pip.py
    

    and get-pip.py file should be in files in the same role

提交回复
热议问题