gpt4 book ai didi

ssh - 在 dokku 部署期间将私有(private)仓库作为依赖项拉取?

转载 作者:行者123 更新时间:2023-12-02 14:02:12 24 4
gpt4 key购买 nike

我在 DigitalOcean 上使用 Dokku 来部署 my_app。我的应用程序有一个指向私有(private)存储库 git@github.com:my_org/my_app.git 的依赖项。

Step 10 : RUN <some_command_to_install_deps>
---> Running in ceada9d96c61
* Getting my_repo (git@github.com:my_org/my_app.git)
remote: verification failed.
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

我尝试使用 https://github.com/cedricziel/dokku-deployment-keys 添加部署 key 无济于事。非常感谢任何帮助。

最佳答案

除了部署 key 插件,您还需要 hostkeys plugingithub.com 添加到容器的 known_hosts 文件中。例如,要在机器上的所有应用程序中批准 github.com,只需执行...

安装插件...

dokku plugin:install https://github.com/cedricziel/dokku-hostkeys-plugin.git hostkeys-keys

然后运行...

sudo dokku hostkeys:shared:autoadd github.com

如果您在执行此操作后仍然遇到问题,则您的部署 key 设置有问题。在这种情况下,请发表评论,我会帮助解决问题

关于ssh - 在 dokku 部署期间将私有(private)仓库作为依赖项拉取?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40836393/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com