我在 VSTS 中有四个阶段的发布管道。开发、测试、预生产和生产。这些阶段共享相同的步骤,唯一的区别是变量值根据阶段而变化。
目前,如果我添加一个新步骤,我必须将其添加到四个阶段,即使它是相同的,唯一的区别是变量的值。
是否有可能有一个由我的四个环境使用的共享阶段,其中唯一的区别是变量。这是为了避免必须添加相同的步骤四次
我的发布管道在工作几个月后今天开始失败。我无法找到有关此错误的任何信息。这是设置System.Debug=true后的相关日志。
2019-06-03T09:12:56.1141807Z Package deployment using ZIP Deploy initiated.
2019-06-03T09:12:56.1227504Z ##[debug][POST]https://$DuoCore__staging:***@xxx-staging.scm.azurewebsites.net/api/zipdeploy?deployer=VSTS&message=%7B%22type%22%3A%22deployment%22%2C%22commitId%22%3A%2241ea351fc04ac594f9a979d19117e494e03c30aa%22%2C%22buildId%22%3A%223477%22%2C%22releaseId%22%3A%221780%22%2C%22buildNumber%22%3A%2220190602.1%22%2C%22releaseName%22%3A%22Release-37%22%2C%22repoProvider%22%3A%22TfsGit%22%2C%22repoName%22%3A%22xxxFront%22%2C%22collectionUrl%22%3A%22https%3A%2F%2Fvectorcuatrogroup.visualstudio.com%2F%22%2C%22teamProject%22%3A%223a39c617-c412-480d-aa54-be5cca265a43%22%2C%22slotName%22%3A%22Staging%22%7D
2019-06-03T09:12:56.2135188Z ##[debug]Could not parse response: {}
2019-06-03T09:12:56.2135454Z ##[debug]Response: undefined
2019-06-03T09:12:56.2137686Z ##[debug]ZIP Deploy response: {"statusCode":403,"statusMessage":"Ip Forbidden","headers":{"content-type":"text/html","server":"Microsoft-IIS/10.0","date":"Mon, 03 Jun 2019 09:12:55 GMT","connection":"close","content-length":"2399"},"body":"<!DOCTYPE html>\r\n<html>\r\n<head>\r\n <title>Web App - Unavailable</title>\r\n <style type=\"text/css\">\r\n html {\r\n height: 100%;\r\n width: 100%;\r\n }\r\n\r\n #feature {\r\n width: 960px;\r\n margin: 95px auto 0 auto;\r\n overflow: auto;\r\n }\r\n\r\n #content {\r\n font-family: \"Segoe UI\";\r\n font-weight: normal;\r\n font-size: 22px;\r\n color: #ffffff;\r\n float: left;\r\n width: 460px;\r\n margin-top: 68px;\r\n margin-left: 0px;\r\n vertical-align: middle;\r\n }\r\n\r\n #content h1 …Run Code Online (Sandbox Code Playgroud) 是否有任何内置的 TFS 构建任务或 PowerShell 脚本可以通过 TFS 中的发布部署管道将文件从 Azure 文件存储复制到 Azure VM。我尝试在互联网上查找一些内容,但没有取得任何成果。
我正在使用发布管道经典编辑器,并且需要将任务中生成的输出变量传递到同一阶段中的多个作业或外部阶段。目前,这个输出变量仅在同一个作业中可用,我必须在多个作业和阶段中编写相同的任务,我觉得这是一种冗余。有什么办法可以实现吗?
devops azure-devops azure-pipelines-release-pipeline azure-devops-rest-api
azure azure-devops azure-pipelines azure-pipelines-release-pipeline
我计划使用 azure devops 发布管道将.NET Web 应用程序部署到测试、uat 和 prod 环境中。
我之前曾参与过具有 appsettings.json 文件并使用变量替换方法的项目,如下面的屏幕截图所示:
在对包含.NET Web 应用程序进行变量替换时web.config,我正在探索以下选项:
azure-devops azure-pipelines azure-pipelines-release-pipeline
我有一个现有的网站,我想使用Visual Studio Team Services在Azure上部署.该网站由静态文件组成,没有ASP.NET或其他任何涉及的内容.
在Visual Studio Team Services中,我创建了一个执行npm install和gulp构建的构建.这将生成一个dist包含该网站所有文件的文件夹.在Azure中,一切都设置正确(订阅,Web应用程序,...).
但是,我不确定如何将我的代码推送到Azure.探索VSTS的Release选项卡中的选项,似乎总是需要'工件',但我只有一堆文件.我需要在文件dist夹中发布文件并确保index.html提供服务.
我怎样才能做到这一点?
这个问题是有关这一之一,然而,答案全部状态,从Azure的开始,并没有提及如何使用Visual Studio团队服务部署现有的代码.
azure azure-web-sites azure-devops azure-pipelines azure-pipelines-release-pipeline
我在VSTS版本管理中有删除文件的任务。我想让内容来自一个变量。我已经创建了一个变量,但是我不知道如何创建多行变量。因此,例如,一个删除三种文件类型的变量:
变量名称= ExcludeFiles
变量值=“库”“ bin \ *。pdb”“ bin \ *。dll.config”
tfs tfsbuild azure-devops azure-pipelines azure-pipelines-release-pipeline
我正在从事的项目有2个长期存在的功能分支以及master分支。
为了完全自动化部署,每当部署从Azure DevOps版本中退出时,我想创建一个从master到这两个功能分支的提取请求。
Azure DevOps中的哪种工具将允许我将发布请求创建为发布任务?
git pull-request azure-devops azure-pipelines azure-pipelines-release-pipeline
我正在尝试拼凑一个Release Gate/ServerGate构建任务,调用Web服务,抓住Json,然后决定是否继续.
服务返回的Json看起来像这样:
{
"publisher": {
"publisherId": "c68591c6-8fbd-413b-b7fb-b921737f4f9f",
"publisherName": "jessehouwing",
"displayName": "Jesse Houwing",
"flags": "verified"
},
"extensionId": "252ad2b4-a2c5-43fc-bba5-17e631896091",
"extensionName": "vsts-snyk",
"displayName": "Snyk Task",
"flags": "validated, public",
"lastUpdated": "2018-03-16T18:58:36.327Z",
"publishedDate": "2016-11-16T21:35:28.387Z",
"releaseDate": "2016-11-16T21:35:28.387Z",
"shortDescription": "Snyk continuously finds and fixes vulnerabilities in your dependencies.",
"versions": [
{
"version": "1.1.12",
"flags": "validated",
"lastUpdated": "2018-03-16T18:58:53.133Z"
},
{
"version": "1.1.11",
"flags": "validated",
"lastUpdated": "2018-02-18T13:53:47.83Z"
}
],
"deploymentType": 0
}
Run Code Online (Sandbox Code Playgroud)
我正在基于task.json中的HttpHandler执行处理程序调用该服务:
"execution": {
"HttpRequest": {
"Execute": {
"EndpointId": "$(connectedServiceName)",
"EndpointUrl": "$(endpoint.url)_apis/gallery/publishers/$(publisherId)/extensions/$(extensionId)$(extensionTag)?flags=1",
"Method": "GET",
"Body": "",
"Headers": …Run Code Online (Sandbox Code Playgroud) continuous-delivery azure-devops azure-pipelines-build-task azure-pipelines-release-pipeline
azure-devops ×10
azure-pipelines-release-pipeline ×10
azure ×4
tfs ×2
devops ×1
git ×1
pull-request ×1
tfsbuild ×1