Migrating Company Communicator between Azure subscriptions

This post has been republished via RSS; it originally appeared at: Microsoft Tech Community - Latest Blogs - .

About Company Communicator (CC)

 

Company Communicator is a custom Teams app that enables corporate teams to create and send messages intended for multiple teams or large number of employees over chat allowing organization to reach employees right where they collaborate. Use CC for multiple scenarios, such as new initiative announcements, employee onboarding, modern learning and development, or organization-wide broadcasts.

 

The app provides an easy interface for designated users to create, preview, collaborate and send messages. It's also a foundation for building custom targeted communication capabilities, such as custom telemetry on how many users acknowledged or interacted with a message.

 

luisdem_1-1665101572850.png

 

 

The official version is available at OfficeDev/microsoft-teams-apps-company-communicator, but in case you want to use extra features like tracking who interacted with your messages (reading, buttons clicked, reactions sent) or using a CSV file to send messages, my suggestion is to use the Cristiano's fork.

 

You can find more details about the Cristiano's version here.

 

How to migrate it between subscriptions

 

It is possible to migrate 99% of CC automatically on Azure Portal except by the "Front Door and CDN profiles" one, that requires you do manually create the resource on the destination subscription.

 

Prerequisites

 

Before starting, make sure that your destination Azure subscription has permission to create the following kinds of resources:

 

  • App Service
  • App Service Plan
  • Bot Channels Registration
  • Azure Function
  • Azure Storage Account
  • Service Bus
  • Application Insights
  • Azure Key vault
  • Microsoft.CDN enabled on Resource Provider

 

Steps

 

  1. From the Azure Portal, go to the Company Communicator Resource Group and click on move:

 

luisdem_25-1665101635724.png

 

 

 

  1. In the Source + target, select the target subscription and resource group to which you want to move the resources. Then select Next:

 

luisdem_26-1665101658392.png

 

 

  1. In the Resource to move, click on Add resources:

 

luisdem_27-1665101683886.png

 

 

  1. Select all resources available, except the Front Door and CDN profiles, and click on Select:

 

luisdem_28-1665101702882.png

 

 

  1. Click on Next to start the validation if it is possible to migrate the items to another subscription:

 

luisdem_29-1665101727934.png

 

 

This step will check whether these resources can be moved, and this might take a few minutes.

In case you forgot to remove the Front Door and CDN profiles, during the validation, you will receive an error saying that the CDN couldn’t be migrated as it is not supported migrating resource types of 'Microsoft.Network/frontdoors.

 

If this is your case, remove the Front Door and CDN profiles item from the list. We will manually create it later from scratch in the target subscription. Click on Next again to start over the migration validation.

 

luisdem_30-1665101762750.png

 

  1. Click on next after having all resources validated:

 

luisdem_31-1665101837983.png

 

 

 

  1. In the Review, check the I understand that tools and scripts associated with moved resources will not work until I update them to use new resource IDs and click Move to start the migration:

 

luisdem_32-1665101856271.png

 

 

After a few minutes, it will remain only the Front Door and CDN profiles in the original resource group:

 

 

luisdem_33-1665101876032.png

 

 

As next step, we need to manually create the Front Door and CDN profiles. Copy all information from your front door and then delete it before proceeding as we want to use the same values.

 

  1. In the Azure Portal, click on Create a resource, search for Front Door and CDN profiles and click on Create:

 

luisdem_34-1665101895215.png

 

 

 

  1. Click on Explore other offerings, select Azure Front Door (classic) and then click on Continue:

 

luisdem_35-1665101911378.png

 

 

  1. Select the target subscription and the target resource group. Then click on Next: Configuration >:

 

luisdem_36-1665101930707.png

 

 

In case you receive the following error message:

 

In order to create this CDN profile, please ensure that Microsoft.CDN is listed as a registered Resource Provider in your Azure subscription.

 

luisdem_37-1665101951034.png

 

 

Switch back to the Azure Portal home, click on Subscriptions, select the target subscription, click on Resource Providers, search for Microsoft.CDN, click on the result item and click on Register:

 

 

luisdem_38-1665101968454.png

 

 

Once registered, switch back to the step 8 to start over the Front Door and CDN profiles creation.

 

  1. In the first blade, click on the plus sign to add the frontend host. Then provide the same name of the original front door, in my case it is ocag422c, and then click on Add:

 

luisdem_39-1665101985707.png

 

 

  1. In the second blade, click on the plus sign to add a backend pool. Name it (I am using the same name as my original one - backendPool1) and click on Add a backend:

 

luisdem_40-1665102005090.png

 

 

  1. Select Custom host in the backend host type, provide the URL of the App Service of your CC (in my case it is ocag422c.azurewebsites.net) for the backend host name and host header, and click on Add:

 

luisdem_41-1665102024014.png

 

 

  1. Add the value /health for the path, select GET for the probe method, 255 for the interval and click on Add:

 

luisdem_42-1665102054860.png

 

 

  1. In the Routing rules blade, click on the plus sign to add a rule:

 

luisdem_43-1665102078586.png

 

 

  1. Name it to routingRule1, change the accepted protocol to HTTPS only and click on Add:

 

luisdem_44-1665102098776.png

 

 

  1. Click again in the Routing rules blade, click on the plus sign to add a second rule.
  • Name it to routingRule2
  • Change the accepted protocol to HTTPS only
  • Change the pattern to match from /* to /api/*
  • Change the route type to Redirect
  • Change the redirect type to Permanent Redirect (308)
  • Select Replace for the destination host and provide the URL of your CC App Service (in my case it is ocag422c.azurewebsites.net)
  • Click on Add

 

luisdem_45-1665102122631.png

 

 

  1. Click on Review + create:

 

luisdem_46-1665102148516.png

 

 

  1. Click on Create to finish.

 

luisdem_47-1665102168752.png

 

 

Done! I hope it helps you!

ヾ(⌐■_■)ノ♪

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.