Azure DevOps 是一個幫助改進 SDLC(軟件開發生命周期)的平臺。
在本文中,我們將使用 Azure Pipelines 創建自動化部署。
Azure DevOps 團隊將 Azure Pipelines 定義為“使用 CI/CD 構建、測試和部署,適用于任何語言、平臺和云平臺”。
在這里,我將解釋如何在 Azure DevOps 中創建構建和發布管道,并將代碼部署到本地服務器。
1. 創建hello world build pipeline
首先創建一個devops build pipeline,該pipeline 生成一個txt文件,并把它作為artifact發布。
trigger:
- main # Adjust if your default branch is differentpool:name: 'agent01'steps:
- script: |echo "Hello, World!" > helloworld.txtdisplayName: 'Create HelloWorld file'- publish: helloworld.txtartifact: hellowor