weixin_39564524 2020-11-30 11:24
浏览 0

Playbook name blank for identical role name and playbook name

From on April 13, 2017 19:51

Galaxy role structured as:


 - defaults/
 - provision_instance.yml
 - meta/
 - tasks/
 - templates/

Requirements.yml


- src: https://github.com/provision_instance
  scm: git

Run: ansible-galaxy install -r requirements.yml --ignore-errors --roles-path roles --force

Expected output:


roles/
 - defaults/
 - provision_instance.yml
 - meta/
 - tasks/
 - templates/

Actual Output:


roles/
 - defaults/
 - .yml
 - meta/
 - tasks/
 - templates/

The provision instance playbook file (provision_instance.yml) has been renamed (.yml).

If I check in a file instance.yml Output


roles/
 - defaults/
 - .yml
 - instance.yml
 - meta/
 - tasks/
 - templates/

Copied from original issue: ansible/galaxy-issues#250

该提问来源于开源项目:ansible/galaxy

  • 写回答

9条回答 默认 最新

  • weixin_39564524 2020-11-30 11:24
    关注

    From on April 14, 2017 14:42

    Additional info:

    It seems if the name of the repo and the name of the playbook match at all, the playbook name is blanked.

    Example:

    Repo Name: consul Playbook Name: deploy_consul.yml

    requirements.yml:

    
    - src: https://github.com/consul
      scm: git
    

    Repo Structure:

    
     - meta/
     - vars/
     - templates/
     - deploy_consul.yml
    

    Expected behavior of ansible-galaxy install -r requirements.yml --ignore-errors --roles-path roles --force:

    
     - meta/
     - vars/
     - templates/
     - deploy_consul.yml
    

    ACTUAL behavior of ansible-galaxy install -r requirements.yml --ignore-errors --roles-path roles --force:

    
     - meta/
     - vars/
     - templates/
     - deploy_.yml
    
    评论

报告相同问题?