简体   繁体   English

是否有任何模板可以同时用于 azure CI/CD 中的逻辑应用和函数应用?

[英]Is there any template which can be used for both Logic Apps and Function Apps in azure CI/CD?

I want to implement CI/CD for both function apps and logic apps.我想为函数应用和逻辑应用实现 CI/CD。

From above 2 posts, I understood that we have different templates for Azure functions and logic apps.So, 2 different build definitions needs to be created if we follow above posts.从以上 2 个帖子中,我了解到我们为 Azure 函数和逻辑应用程序提供了不同的模板。因此,如果我们遵循以上帖子,则需要创建 2 个不同的构建定义。

I have logic apps and function apps in same develop branch.我在同一个开发分支中有逻辑应用程序和功能应用程序。

Is there any way to create single build definition instead of multiple build definitions.有什么方法可以创建单个构建定义而不是多个构建定义。

Is there any way to create single build definition instead of multiple build definitions.有什么方法可以创建单个构建定义而不是多个构建定义。

As the comment said, you can define these 2 different build definition in one Build pipeline by using 2 agent jobs .正如评论所说,您可以使用2 个代理作业在一个构建管道中定义这 2 个不同的构建定义。

  • Build pipeline definition :构建管道定义

在此处输入图片说明

Note: As you said, you stored logic apps and function apps in same develop branch.注意:正如您所说,您将logic appsfunction apps存储在同一个开发分支中。 Please specified exactly on Path to publish when you run the publish build artifact task.请在运行publish build artifact任务时准确指定Path to publish

And then, you will see that it will generated 2 artifacts which for 2 different application.然后,您将看到它将为 2 个不同的应用程序生成 2 个工件。

在此处输入图片说明


  • Release pipeline definition :发布管道定义

Since these are different app, please configure into 2 stages.由于这些是不同的应用程序,请配置为2 个阶段。 One is for Logic app, and another is for Azuer function app:一个用于 Logic 应用程序,另一个用于 Azuer 函数应用程序:

在此处输入图片说明

The most important part is filter artifacts for corresponding stage.最重要的部分是相应阶段的过滤器工件。 We just now generate 2 artifacts in one build pipeline.我们刚刚在一个构建管道中生成了 2 个工件。 So here, we must filter out the corresponding artifacts and deploy it into the correct stage.所以在这里,我们必须过滤掉相应的工件并将其部署到正确的阶段。

In the definition part of agent job, you can filter out the artifact by specifying as below shown:在代理作业的定义部分,您可以通过指定如下所示来过滤工件:

在此处输入图片说明

Then configure the release task based on corresponding app artifact.然后根据对应的app artifact配置发布任务。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM