|
| 1 | +--- |
| 2 | +title: Create Apache Kafka for Confluent Cloud through Azure CLI - Azure partner solutions |
| 3 | +description: This article describes how to use the Azure CLI to create an instance of Apache Kafka for Confluent Cloud. |
| 4 | +ms.service: partner-services |
| 5 | +ms.topic: quickstart |
| 6 | +ms.date: 11/03/2021 |
| 7 | +author: tfitzmac |
| 8 | +ms.author: tomfitz |
| 9 | +ms.custom: devx-track-azurepowershell |
| 10 | +--- |
| 11 | + |
| 12 | +# QuickStart: Get started with Apache Kafka for Confluent Cloud - Azure CLI |
| 13 | + |
| 14 | +In this quickstart, you'll use the Azure Marketplace and Azure CLI to create an instance of Apache Kafka for Confluent Cloud. |
| 15 | + |
| 16 | +## Prerequisites |
| 17 | + |
| 18 | +- An Azure account. If you don't have an active Azure subscription, create a [free account](https://azure.microsoft.com/free/). |
| 19 | +- You must have the _Owner_ or _Contributor_ role for your Azure subscription. The integration between Azure and Confluent can only be set up by users with _Owner_ or _Contributor_ access. Before getting started, [confirm that you have the appropriate access](../../role-based-access-control/check-access.md). |
| 20 | + |
| 21 | +## Find offer |
| 22 | + |
| 23 | +Use the Azure portal to find the Apache Kafka for Confluent Cloud application. |
| 24 | + |
| 25 | +1. In a web browser, go to the [Azure portal](https://portal.azure.com/) and sign in. |
| 26 | + |
| 27 | +1. If you've visited the **Marketplace** in a recent session, select the icon from the available options. Otherwise, search for _Marketplace_. |
| 28 | + |
| 29 | + :::image type="content" source="media/marketplace.png" alt-text="Marketplace icon."::: |
| 30 | + |
| 31 | +1. From the **Marketplace** page, you have two options based on the type of plan you want. You can sign up for a pay-as-you-go plan or commitment plan. Pay-as-you-go is publicly available. The commitment plan is available to customers who have been approved for a private offer. |
| 32 | + |
| 33 | + - For **pay-as-you-go** customers, search for _Apache Kafka on Confluent Cloud_. Select the offer for Apache Kafka on Confluent Cloud. |
| 34 | + |
| 35 | + :::image type="content" source="media/search-pay-as-you-go.png" alt-text="search Azure Marketplace offer."::: |
| 36 | + |
| 37 | + - For **commitment** customers, select the link to **View Private offers**. The commitment requires you to sign up for a minimum spend amount. Use this option only when you know you need the service for an extended time. |
| 38 | + |
| 39 | + :::image type="content" source="media/view-private-offers.png" alt-text="view private offers."::: |
| 40 | + |
| 41 | + Look for _Apache Kafka on Confluent Cloud_. |
| 42 | + |
| 43 | + :::image type="content" source="media/select-from-private-offers.png" alt-text="select private offer."::: |
| 44 | + |
| 45 | +## Create resource |
| 46 | + |
| 47 | +After you've selected the offer for Apache Kafka on Confluent Cloud, you're ready to set up the application. |
| 48 | + |
| 49 | +### [Azure CLI](#tab/azure-cli) |
| 50 | + |
| 51 | +Start by preparing your environment for the Azure CLI: |
| 52 | + |
| 53 | +[!INCLUDE [azure-cli-prepare-your-environment-no-header.md](../../../includes/azure-cli-prepare-your-environment-no-header.md)] |
| 54 | + |
| 55 | +After you sign in, use the [az confluent organization create](/cli/azure/confluent/organization#az_confluent_organization_create) command to create the new organization resource: |
| 56 | + |
| 57 | +```azurecli |
| 58 | +az confluent organization create --name "myOrganization" --resource-group "myResourceGroup" \ |
| 59 | + --location "my location" \ |
| 60 | + --offer-detail id="string" plan-id="string" plan-name="string" publisher-id="string" term-unit="string" \ |
| 61 | + --user-detail email-address="[email protected]" first-name="string" last-name="string" \ |
| 62 | + --tags Environment="Dev" |
| 63 | +``` |
| 64 | + |
| 65 | +> [!NOTE] |
| 66 | +> If you want the command to return before the create operation completes, add the optional parameter `--no-wait`. The operation continues to run until the Confluent organization is created. |
| 67 | +
|
| 68 | +To pause CLI execution until an organization's specific event or condition occurs, use the [az confluent organization wait](/cli/azure/confluent/organization#az_confluent_organization_wait) command. For example, to wait until an organization is created: |
| 69 | + |
| 70 | +```azurecli |
| 71 | +az confluent organization wait --name "myOrganization" --resource-group "myResourceGroup" --created |
| 72 | +``` |
| 73 | + |
| 74 | +To see a list of existing organizations, use the [az confluent organization list](/cli/azure/confluent/organization#az_confluent_organization_list) command. |
| 75 | + |
| 76 | +You can view all of the organizations in your subscription: |
| 77 | + |
| 78 | +```azurecli |
| 79 | +az confluent organization list |
| 80 | +``` |
| 81 | + |
| 82 | +Or, view the organizations in a resource group: |
| 83 | + |
| 84 | +```azurecli |
| 85 | +az confluent organization list --resource-group "myResourceGroup" |
| 86 | +``` |
| 87 | + |
| 88 | +To see the properties of a specific organization, use the [az confluent organization show](/cli/azure/confluent/organization#az_confluent_organization_show) command. |
| 89 | + |
| 90 | +You can view the organization by name: |
| 91 | + |
| 92 | +```azurecli |
| 93 | +az confluent organization show --name "myOrganization" --resource-group "myResourceGroup" |
| 94 | +``` |
| 95 | + |
| 96 | +Or, view the organization by resource ID: |
| 97 | + |
| 98 | +```azurecli |
| 99 | +az confluent organization show --ids "/subscriptions/{SubID}/resourceGroups/{myResourceGroup}/providers/Microsoft.Confluent/organizations/{myOrganization}" |
| 100 | +``` |
| 101 | + |
| 102 | +### [Azure PowerShell](#tab/azure-powershell) |
| 103 | + |
| 104 | +Start by preparing your environment for Azure PowerShell: |
| 105 | + |
| 106 | +[!INCLUDE [azure-powershell-requirements-no-header.md](../../../includes/azure-powershell-requirements-no-header.md)] |
| 107 | + |
| 108 | +> [!IMPORTANT] |
| 109 | +> While the **Az.Confluent** PowerShell module is in preview, you must install it separately using the `Install-Module` cmdlet. |
| 110 | +
|
| 111 | +```azurepowershell |
| 112 | +Install-Module -Name Az.Confluent -Scope CurrentUser -Repository PSGallery -Force |
| 113 | +``` |
| 114 | + |
| 115 | +After you sign in, use the [New-AzConfluentOrganization](/powershell/module/az.confluent/new-azconfluentorganization) cmdlet to create the new organization resource: |
| 116 | + |
| 117 | +```azurepowershell |
| 118 | +$ConfluentOrgParams = @{ |
| 119 | + Name = 'myOrganization' |
| 120 | + ResourceGroupName = 'myResourceGroup' |
| 121 | + Location = 'my location' |
| 122 | + OfferDetailId = 'string' |
| 123 | + OfferDetailPlanId = 'string' |
| 124 | + OfferDetailPlanName = 'string' |
| 125 | + OfferDetailPublisherId = 'string' |
| 126 | + OfferDetailTermUnit = 'string' |
| 127 | + UserDetailEmailAddress = '[email protected]' |
| 128 | + UserDetailFirstName = 'string' |
| 129 | + UserDetailLastName = 'string' |
| 130 | + Tag = @{Environment='Dev'} |
| 131 | +} |
| 132 | +
|
| 133 | +New-AzConfluentOrganization @ConfluentOrgParams |
| 134 | +``` |
| 135 | + |
| 136 | +> [!NOTE] |
| 137 | +> If you want the command to return before the create operation completes, add the optional parameter `-NoWait`. The operation continues to run until the Confluent organization is created. |
| 138 | +
|
| 139 | +To see a list of existing organizations, use the [Get-AzConfluentOrganization](/powershell/module/az.confluent/get-azconfluentorganization) cmdlet. |
| 140 | + |
| 141 | +You can view all of the organizations in your subscription: |
| 142 | + |
| 143 | +```azurepowershell |
| 144 | +Get-AzConfluentOrganization |
| 145 | +``` |
| 146 | + |
| 147 | +Or, view the organizations in a resource group: |
| 148 | + |
| 149 | +```azurepowershell |
| 150 | +Get-AzConfluentOrganization -ResourceGroupName myResourceGroup |
| 151 | +``` |
| 152 | + |
| 153 | +To see the properties of a specific organization, use the `Get-AzConfluentOrganization` cmdlet with the `Name` and `ResourceGroupName` parameters. |
| 154 | + |
| 155 | +You can view the organization by name: |
| 156 | + |
| 157 | +```azurepowershell |
| 158 | +Get-AzConfluentOrganization -Name myOrganization -ResourceGroupName myResourceGroup |
| 159 | +``` |
| 160 | + |
| 161 | +--- |
| 162 | + |
| 163 | +If you get an error, see [Troubleshooting Apache Kafka for Confluent Cloud solutions](troubleshoot.md). |
| 164 | + |
| 165 | +## Next steps |
| 166 | + |
| 167 | +> [!div class="nextstepaction"] |
| 168 | +> [Manage the Confluent Cloud resource](manage.md) |
0 commit comments