git - 无法解析主机名:从 CircleCI 作业推送到 Github 私人仓库时
问题描述
我正在研究 Github-CircleCI 集成。我的一项工作是将 git 标签推送到同一个存储库。但是每次我尝试这样做时,都会收到以下错误:
ssh: Could not resolve hostname : Name or service not known
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
我按照文档https://circleci.com/docs/2.0/gh-bb-integration/#creating-a-github-deploy-key中提到的步骤进行操作。但这不起作用。我确保我对我的新部署密钥具有写入权限。我还在我的 yml 文件中添加了指纹。
version: 2.0
jobs:
deploy:
steps:
- add_ssh_keys:
fingerprints:
- "<FINGERPRINT>"
- checkout
- run:
name: deploy
command: |
git tag -a v1.0.0 -m "test tag"
echo "tag created"
git push origin v1.0.0
echo "tag pushed"
workflows:
version: 2
build-and-deploy:
jobs:
- deploy:
filters:
branches:
only:
- /^test/
我成功创建了标签。但是每当它尝试推送标签时,它就会出现上述错误。
谁能指出丢失的东西?任何帮助表示赞赏!
解决方案
推荐阅读
- c++ - C++模板类,基于类型名改变类方法的行为
- html - 我应该如何将此 div 内的文本移动到底部中心?
- python - 如何在网络分析中将主要社区标记到节点
- ios - Xcode 9.4 无法打开文件“my_app”,因为您无权查看它
- javascript - Joomla-将值从文章发送到文章
- python-3.x - 使用 Selenium 和 Python3 为文本添加唯一时间戳
- php - Laravel 使用 map() 并返回查看 + 获取 youtube 视频 ID
- rest - 将 PathParams 和 QueryParams 聚合到一个 Bean 中
- kubernetes - 初始化程序(initializerConfiguration)在 k8s 1.10 上工作吗?
- sql - 如何加入日期列和时间列