< Previous Challenge - Home - Next Challenge >
For our microservices based architecture, we're going to use containers for our microservices and deploy them using Azure Container Instances as the quickest way to get containers up and running in Azure. In this challenge you will be tasked with doing this and in the process will learn how quick and easy it is.
- There are three different containers you are going to deploy as Azure Container Instances
- Data API:
microservicesdiscovery/travel-data-service
- Itinerary API:
microservicesdiscovery/travel-itinerary-service
- DataLoader utility (to setup and seed Cosmos DB):
microservicesdiscovery/travel-dataloader
- All of these containers will need 3 environment variables defined:
DataAccountName
: Name of the Cosmos DB AccountDataAccountPassword
: Primary Key of the Cosmos DB AccountApplicationInsights__InstrumentationKey
: Instrumentation Key of the App Insights Resource
- The Data API and Itinerary API containers, both need to specify a DNS Name, so they are easily addressable by the Web Site.
- After you get the Data API deployed, use the Azure CLI to query the deployed container for its full qualified domain name (FQDN) and store it in a variable called:
dataServiceUri
- After you get the Itinerary API deployed, use the Azure CLI to query the deployed container for the FQDN and store it in a variable called:
itineraryServiceUri
- After you get the Data API deployed, use the Azure CLI to query the deployed container for its full qualified domain name (FQDN) and store it in a variable called:
- Verify the Data Service by browsing the URL:
http://$dataServiceUri/api/airport
- It should return a list of Airports
- Verify the Itinerary Service by browsing the URL:
http://$itineraryServiceUri/api/itinerary/AAA
- It should return a 204.
- NOTE: It should return a 404, but to get a positive test response, it returns a 204 (which represents “no content”) to verify the service is up and running.
- After you get the DataLoader deployed, you can see what it actually did by viewing its logs.
- Use the Azure CLI to print out the logs for the Data Loader container.
- Try this with the other containers as well just for fun.
- You have deployed the 3 containers into Azure Container Instances.
- You have verified the Data Service end point URL.
- You have verified the Itinerary Service end point URL.
- You have successfully using the CLI to query the container logs.