To ensure a smooth workshop experience, we need to set up your environment correctly. This includes creating an Azure subscription using the provided Azure pass and preparing your code environment with the necessary tools.
Your Azure Pass provides a $100 USD credit for you to use with Azure, enabling you to create various resources as part of this workshop. Follow these steps to redeem your pass:
-
Open a new private browser window. This ensures you don't accidentally link the Azure pass to an existing Microsoft Account or work account. Navigate to the Microsoft Azure Pass website and click the "Start" button.
-
Create a new Azure Account.
-
Enter the provided Promo Code.
Upon successful redemption, you'll have a newly setup Azure subscription.
To prepare your code environment for the workshop, you need to install the following tools:
-
VSCode, or IntelliJ
-
GitHub Copilot extension for VSCode or IntelliJ. Codespaces already has GitHub Copilot extension installed.
-
Azure CLI version 2.64.0 or higher. You can check the version of your current Azure CLI installation by running:
az --version
Signing In with Azure CLI Login to Azure from the CLI with the following command, and complete the prompts to authenticate:
az loginNext, install or update the necessary Azure CLI extensions for our labs
az extension add --name containerapp --upgrade --allow-preview true
az extension add --name serviceconnector-passwordless --upgrade --allow-preview trueAzure resource providers is to enable functionality for a specific Azure service. Some resource providers are registered by default. For a list of resource providers registered by default, see Resource providers for Azure services.
Let's register the required Azure resource providers for our labs:
az config set extension.use_dynamic_install=yes_without_prompt
az provider register --namespace Microsoft.App
az provider register --namespace Microsoft.OperationalInsights
az provider register --namespace Microsoft.ServiceLinkerThis workshop provides Bicep templates to deploy the necessary resources to Azure. In case you're using your own laptop, please git clone the project first. If you're using GitHub Codespaces, the project is already cloned for you so you don't need to do anything.
git clone https://github.com/eggboy/aca-java-ai-workshop
cd aca-java-ai-workshopRun the command azd up in the $HOME directory to deploy the necessary resources to Azure. This will create resources
in your Azure subscription, including:
- Resource Group
aca-labs - Log Analytics workspace
- Azure Service Bus Namespace and Queue
keda - Azure OpenAI Endpoint
- Azure Container Apps Environment
- Azure Database for MySQL Flexible Server
This is an example of outputs:
$ azd up
? Select an Azure location to use: 1. (Asia Pacific) East Asia (eastasia)
Packaging services (azd package)
Provisioning Azure resources (azd provision)
Provisioning Azure resources can take some time.
Subscription: ... (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx)
Location: East Asia
You can view detailed progress in the Azure Portal:
https://portal.azure.com/#view/...
(✓) Done: Resource group: aca-labs-vyhjztie4zgue (7.168s)
(✓) Done: Log Analytics workspace: log-vyhjztie4zgue (4.19s)
(✓) Done: Service Bus Namespace: sb-vyhjztie4zgue (22.363s)
(✓) Done: Azure OpenAI: cog-vyhjztie4zgue (29.06s)
(✓) Done: Azure AI Services Model Deployment: cog-vyhjztie4zgue/gpt-4o (30.675s)
(✓) Done: Container Apps Environment: cae-vyhjztie4zgue (1m46.019s)
(✓) Done: Azure Database for MySQL flexible server: mysql-vyhjztie4zgue (7m14.054s)
Deploying services (azd deploy)
SUCCESS: Your up workflow to pro vision and deploy to Azure completed in 8 minutes 3 seconds.azd up will return the name of resources created in your Azure subscription. Please go
to Azure Portal to verify the resources in the resource gorup aca-labs
[!IMPORTANT] To ensure easy access to Azure Container Apps, set your default settings:
az configure --defaults location={Location(eastasia or koreacentral) you selected during `azd up`} group={Resource group name created by `azd up` command. It's `aca-labs-vyhjztie4zgue` in the example above}Also, export the name of Azure Container Apps Environment which is created by azd up command:
export ACA_ENVIRONMENT_NAME={Azure Container Apps Environment created by `azd up` command. It's `cae-vyhjztie4zgue` in the example above}


