14.07.2020, 21:16 | #1 |
Участник
|
waldo: Deploying from DevOps the right way (Part 2): Deploying to OnPrem Business Central environments with the automation API
Источник: https://dynamicsuser.net/nav/b/waldo...automation-api
============== You might have read my previous blogpost on how to enable the “external deployment” in an OnPrem Business Central environment. Well, that post deserved an “extension” as I didn’t provide examples on how to deploy with PowerShell – which you would be able to do within Azure DevOps. Scenario The scenario is still the same: you have all these OnPrem customers, where you would like to deploy your apps to. Microsoft is clear: just install a DevOps agent on all those customers. The alternative that I try to give is – well, don’t install the devops agent, but just make “External Deployment” possible by following my steps in my previous post, and use the Automation API, just like you would for Business Central SaaS. Sidenote: this API needs to be accessible from your company. So we make sure that the customer enables our IP in their firewall to be able to access this automation API directly from our location. PowerShell Since I don’t use PowerShell in DevOps (suplise, suplise), I created an example-script for you in my repo here: https://github.com/waldo1001/Cloud.R...omationAPI.ps1 Just a few things worth to mention:
ALOps As said, I don’t use PowerShell anymore, because I’m using ALOps, just because it so much more hassle-free .. and we see that many people are starting to use ALOps as well, also for community purposes. Nice! This means community projects are also getting decent build pipeline in stead of none – and it’s free, so why not ;-). In ALOps, we created the “ALOps Extension API” step, which you can use to publish an extension through the Automation API OnPrem. The easiest way to do that is by simply introduce one step, and set the “Batch Publish” interaction. Basically it will get all app-files you selected as artifacts, figure out the order to publish for you, and install all artifacts that you have set up in your release-step. Easy peasy. It doesn’t care if it’s in Docker or not .. If the endpoint is available, the external deployer is installed, then your publish will work. Here is the setup in the classic editor which releases 22 apps – one simple step, with only 1 real parameter to fill: Or in yaml: steps: - task: hodor.hodor-alops.ALOpsExtensionAPI.ALOpsExtensionAPI@1 displayName: 'Batch Publish' inputs: interaction: batch api_endpoint: 'https://thedestinationbc/bc/api' authentication: windows Источник: https://dynamicsuser.net/nav/b/waldo...automation-api
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору. |
|
|
Опции темы | Поиск в этой теме |
Опции просмотра | |
|