github - 在 shinyapp.io 上部署 Shiny 的应用程序,并在私有(private)组织仓库中使用包

标签 github deployment repository rstudio shinyapps

我正在尝试将 Shiny 的应用程序部署到 shinyapps.io 服务器,但不断收到与托管在我们组织拥有的私有(private) github 存储库中的定制包相关的错误(请注意,我已经替换了实际名称以下错误中的包、公司名称和私有(private)仓库名称):

error: Building package: [PACKAGE NAME]
################################ Begin Task Log 
################################ 
################################# End Task Log 
################################# 
Error: Unhandled Exception: Child Task 530176316 failed: Error building 
image: Error fetching [PACKAGE NAME] (1.0.2) source. Error accessing GitHub 
repository ORGANIZATION/PRIVATE_REPO. HTTP 404: Not Found

我知道 repo 链接很好,因为通过 devtools::install_github("ORGANIZATION/PRIVATE_REPO, auth_token = token 安装作品。
我是组织页面的管理员,并确保 token同时具有 repo 和 admin:org 范围。

我还确保在我的 shinyapps.io 帐户页面中勾选“私有(private)存储库访问”,如 here 所述。 .

有人对我可能做错了什么有任何想法吗?

谢谢!

最佳答案

创建 .Rprofile您打算部署的项目文件夹中的文件。

您需要在 .Rprofile 中设置该 repo 选项。 .并添加您的私有(private) github 链接。就像是

# A sample .Rprofile file with two different package repositories.
local({
  r <- getOption("repos")
  r["CRAN"] <- "https://cran.rstudio.com/"
  r["mycompany"] <- "http://rpackages.mycompany.com/"
  options(repos = r)
})

这在这里得到了很好的解释。 Package management in RStudio Connect .

关于github - 在 shinyapp.io 上部署 Shiny 的应用程序,并在私有(private)组织仓库中使用包,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/50729735/

相关文章:

Github)3路 merge ,补丁

deployment - Windows Azure 和持续集成

Git/GitHub 一个账号贡献的总行数

github - SonarQube jenkins 插件对于 URL : https://api. github.com/user 返回 "Server returned HTTP response code: -1, message: ' null'”

c# - Windows7 Installer优先使用C#如何在安装过程中将其移回?

entity-framework - 首先部署 Entity Framework 代码

linux - GIT 权限 : Repository inside a repository

svn - 350GB SVN repo 为即使是最简单的任务(如分支/标记)创建至少 1MB 的修订版

macos - 如何使用 homebrew 获取 avidemux

git - 如何将大型 NextJS 项目推送到 GitHub