小编Sup*_*a K的帖子

ansible剧本上的错误:找不到与“ python-pip”匹配的软件包-on centos guest

我正在尝试通过Ansible剧本在centos guest虚拟机(通过无业游民旋转)上安装一些软件包。这是我尝试安装的代码段

- name: Installing helpful tools and packages
   yum:
    pkg: "{{ item }}"
    state: present
  with_items:
    - ntp
    - tcpdump
    - policycoreutils-python
    - vim
    - vim-X11
    - yum-utils
    - deltarpm
    - git
    - ntp
    - python-pip
    - pip
  when:
    - ansible_os_family == "RedHat"

- name: Install shade using pip.
  #become: yes
  pip:
    name: "{{ item }}"
    state: present
  with_items:
    - pip
    - shade
Run Code Online (Sandbox Code Playgroud)

这是我收到的错误。无法获取“ python-pip”

TASK [prep : Installing helpful tools and packages] 
****************************
failed: [default] (item=[u'ntp', u'tcpdump', u'policycoreutils-python', …
Run Code Online (Sandbox Code Playgroud)

python pip ansible

1
推荐指数
1
解决办法
3295
查看次数

标签 统计

ansible ×1

pip ×1

python ×1