带有私有 Docker 集线器的 Azure DevOps CD 管道
Azure DevOps CD Pipeline with private Docker Hub
我正在尝试在 Azure DevOps 中为我的应用程序创建一个 CI/CD 管道。使用“构建管道”部分我没有问题。这是一个通过 Docker 容器构建和托管 (nginx) 的 React 应用程序。因此,构建 Docker 容器并将其推送到我的私有 Docker 集线器是没有问题的,这将 work.But 我实际上无法弄清楚如何配置发布管道以部署到 Azure具有私有 Docker 集线器的容器 WebApp。因为没有用于配置服务连接或登录凭据的选项。如果有人可以帮助我并给出提示,那就太好了。
谢谢
But I actually can't figure out how to configure the release pipeline
to deploy to a Azure WebApp for Containers with a private Docker Hub.
Because there is no option for a service connection or Login
Credentials to Configure. Would be nice if someone could help me and
give a hint.
您不需要在 Azure Web App For containers
任务或 Azure App Service Deploy
任务中提供 service connection or Login Credentials of private Docker Hub
。
相反,您应该在 Azure Web Portal
中配置凭据。转到 Azure Web Portal
=>App Service=>Settings=>Container Settings,您将看到:
您可以在那里输入您的凭据,或者您可以在创建 Azure 应用服务时配置凭据。
由于您的 Azure App Service
可以访问您的私有 Docker 集线器,并且 Azure Devops 管道中的部署任务可以使用 Azure Subscription
输入访问 Azure App Service
,因此 Azure WebApp for Containers
任务可以自动访问 Private Docker Hub 注册表。 (这就是为什么您没有 have/need 提供私有 docker 集线器凭据的选项!)
我正在尝试在 Azure DevOps 中为我的应用程序创建一个 CI/CD 管道。使用“构建管道”部分我没有问题。这是一个通过 Docker 容器构建和托管 (nginx) 的 React 应用程序。因此,构建 Docker 容器并将其推送到我的私有 Docker 集线器是没有问题的,这将 work.But 我实际上无法弄清楚如何配置发布管道以部署到 Azure具有私有 Docker 集线器的容器 WebApp。因为没有用于配置服务连接或登录凭据的选项。如果有人可以帮助我并给出提示,那就太好了。 谢谢
But I actually can't figure out how to configure the release pipeline to deploy to a Azure WebApp for Containers with a private Docker Hub. Because there is no option for a service connection or Login Credentials to Configure. Would be nice if someone could help me and give a hint.
您不需要在 Azure Web App For containers
任务或 Azure App Service Deploy
任务中提供 service connection or Login Credentials of private Docker Hub
。
相反,您应该在 Azure Web Portal
中配置凭据。转到 Azure Web Portal
=>App Service=>Settings=>Container Settings,您将看到:
您可以在那里输入您的凭据,或者您可以在创建 Azure 应用服务时配置凭据。
由于您的 Azure App Service
可以访问您的私有 Docker 集线器,并且 Azure Devops 管道中的部署任务可以使用 Azure Subscription
输入访问 Azure App Service
,因此 Azure WebApp for Containers
任务可以自动访问 Private Docker Hub 注册表。 (这就是为什么您没有 have/need 提供私有 docker 集线器凭据的选项!)