简体   繁体   English

Unable to install ansible collections from a private git repository using Https and SSH link

[英]Unable to install ansible collections from a private git repository using Https and SSH link

I am getting the below error it works with the tar file which i need to clone and install.我收到以下错误,它适用于我需要克隆和安装的 tar 文件。 As per ansible document we can install using the below methods.根据 ansible 文档,我们可以使用以下方法安装。

https://docs.ansible.com/ansible/latest/galaxy/user_guide.html#installing-a-collection-from-a-git-repository https://docs.ansible.com/ansible/latest/galaxy/user_guide.html#installing-a-collection-from-a-git-repository

why is it asking for tar file in my case?为什么在我的情况下要求 tar 文件?

[root@oc1546875**4 collections_repository1]# ansible-galaxy collection install git@github.i m.com:samnanajeeb/test_collections.git Process install dependency map ERROR. [root@oc1546875**4 collections_repository1]# ansible-galaxy collection install git@github.i m.com:samnanajeeb/test_collections.git Process install dependency map ERROR. Invalid collection name 'git@github.i m.com', name must be in the format.. Please make sure namespace and collection name contains characters from [a-zA-Z0-9_] only.集合名称 'git@github.im.com'无效,名称必须采用格式。请确保命名空间和集合名称仅包含 [a-zA-Z0-9_] 中的字符。

[root@oc1546875**4 collections_repository2]# ansible-galaxy collection install https://github.i*m.com/Ansible-Self-Study/collections_repository1.git Process install dependency map ERROR. [root@oc1546875**4 collections_repository2]# ansible-galaxy collection install https://github.i*m.com/Ansible-Self-Study/collections_repository1.git Process install dependency map ERROR. Collection artifact at '/root/.ansible/tmp/ansible-local-7328qnvhfs/tmpOWt66o/collections_repository1SxEx78.git' is not a valid tar file. '/root/.ansible/tmp/ansible-local-7328qnvhfs/tmpOWt66o/collections_repository1SxEx78.git' 处的集合工件不是有效的 tar 文件。

The docs specify that one must prefix https: with git+https: in order to advise ansible the URL does not just produce bytes but must be git installed. The docs specify that one must prefix https: with git+https: in order to advise ansible the URL does not just produce bytes but must be git installed. I would guess, based on my experiences with ansible coding practices, that your first error is caused by them hard-coding github.com , so try git+ssh://git@github.im.com/samn.../test_collections.git to (for the same reason) advise ansible that the path needs to be git cloned我猜,根据我对 ansible 编码实践的经验,你的第一个错误是由他们硬编码github.com引起的,所以试试git+ssh://git@github.im.com/samn.../test_collections.git . git+ssh://git@github.im.com/samn.../test_collections.git (出于同样的原因)建议ansible该路径需要被git克隆

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 TortoiseGit:无法使用SSH在VPS上使用Git克隆私有存储库 - TortoiseGit: Unable to Git clone private repository on VPS using SSH 无法使用 https 和 Z765553E6C7AC85A00AZ 链接9ACB8 克隆 Eclipse 中的 git 存储库 - Unable to clone git repository in Eclipse using https and SSH links 由于私有git存储库ssh和https连接,npm安装失败 - npm install fails due to private git repository both ssh and https connections 使用 Ansible 无需 ssh 将特定文件从私有 git 存储库复制到远程服务器的任何替代方法 - Any alternative way to copy specific file from private git repository to remote server with Ansible without ssh Git 使用 HTTPS 访问私有存储库 - Git access to private repository using HTTPS 无法使用SSH克隆GIT存储库 - Unable to clone GIT repository using SSH Jenkins 管道中的 Git 使用错误的 SSH 私钥推回 Git 存储库 - Git from Jenkins pipeline is using wrong SSH private key to push back into Git repository 使用 ssh 或 https 从私有 git repo 安装 pip requirements.txt - Installing with pip requirements.txt from a private git repo using ssh OR https 尽管仅提供ssh访问,但仍使用https访问git存储库 - Accessing a git repository using https, despite it providing ssh access only 不具有.git目录的Composer从私有GIT存储库安装软件包 - Composer install package from private GIT repository without the .git directory
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM