Skip to main content

n_groups

Creates, updates, deletes, gets or lists a n_groups resource.

Overview

Namen_groups
TypeResource
Idazure.container_instance.n_groups

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
containerGroupProfilesarrayThe Container Group Profiles that could be used in the NGroups resource.
elasticProfileobjectThe elastic profile.
identityobjectThe identity of the NGroup, if configured.
locationstringThe geo-location where the resource lives.
placementProfileobjectProvides options w.r.t allocation and management w.r.t certain placement policies. These utilize capabilities provided by the underlying Azure infrastructure. They are typically used for high availability scenarios. E.g., distributing CGs across fault domains.
provisioningStatestringThe provisioning state, which only appears in the response. Known values are: "Creating", "Updating", "Failed", "Succeeded", "Canceled", "Deleting", and "Migrating". (Creating, Updating, Failed, Succeeded, Canceled, Deleting, Migrating)
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
tagsobjectResource tags.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
updateProfileobjectUsed by the customer to specify the way to update the Container Groups in NGroup.
zonesarrayThe availability zones.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, ngroups_name, subscription_idNGroups GET REST API. Get the properties of the specified NGroups resource.
list_by_resource_groupselectresource_group_name, subscription_idGET NGroups under a resource group REST API. Gets a list of all NGroups resources under a resource group.
listselectsubscription_idList NGroups in a subscription. Gets a list of all NGroups resources under a subscription.
create_or_updateinsertresource_group_name, ngroups_name, subscription_idNGroup PUT REST API. Create or update a NGroups resource.
updateupdateresource_group_name, ngroups_name, subscription_idNGroups PATCH REST API. Update a specified NGroups resource.
create_or_updatereplaceresource_group_name, ngroups_name, subscription_idNGroup PUT REST API. Create or update a NGroups resource.
deletedeleteresource_group_name, ngroups_name, subscription_idNGroups Delete REST API. Deletes the NGroups resource.
startexecresource_group_name, ngroups_name, subscription_idStarts all container groups in the specified NGroups resource. Starts all container groups in the specified NGroups resource. Compute resources will be allocated and billing will start.
stopexecresource_group_name, ngroups_name, subscription_idStops all container groups in the specified NGroups resource. Stops all container groups in the specified NGroups resource. Compute resources will be deallocated and billing will stop.
restartexecresource_group_name, ngroups_name, subscription_idRestarts all container groups in the specified NGroups resource. Restarts all container groups in the specified NGroups resource in place. If container image has updates, new image will be downloaded.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
ngroups_namestringThe NGroups name. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring

SELECT examples

NGroups GET REST API. Get the properties of the specified NGroups resource.

SELECT
id,
name,
containerGroupProfiles,
elasticProfile,
identity,
location,
placementProfile,
provisioningState,
systemData,
tags,
type,
updateProfile,
zones
FROM azure.container_instance.n_groups
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND ngroups_name = '{{ ngroups_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

NGroup PUT REST API. Create or update a NGroups resource.

INSERT INTO azure.container_instance.n_groups (
properties,
tags,
location,
zones,
identity,
resource_group_name,
ngroups_name,
subscription_id
)
SELECT
'{{ properties }}',
'{{ tags }}',
'{{ location }}',
'{{ zones }}',
'{{ identity }}',
'{{ resource_group_name }}',
'{{ ngroups_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
identity,
location,
properties,
systemData,
tags,
type,
zones
;

UPDATE examples

NGroups PATCH REST API. Update a specified NGroups resource.

UPDATE azure.container_instance.n_groups
SET
properties = '{{ properties }}',
identity = '{{ identity }}',
tags = '{{ tags }}',
zones = '{{ zones }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND ngroups_name = '{{ ngroups_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
identity,
location,
properties,
systemData,
tags,
type,
zones;

REPLACE examples

NGroup PUT REST API. Create or update a NGroups resource.

REPLACE azure.container_instance.n_groups
SET
properties = '{{ properties }}',
tags = '{{ tags }}',
location = '{{ location }}',
zones = '{{ zones }}',
identity = '{{ identity }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND ngroups_name = '{{ ngroups_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
RETURNING
id,
name,
identity,
location,
properties,
systemData,
tags,
type,
zones;

DELETE examples

NGroups Delete REST API. Deletes the NGroups resource.

DELETE FROM azure.container_instance.n_groups
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND ngroups_name = '{{ ngroups_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;

Lifecycle Methods

Starts all container groups in the specified NGroups resource. Starts all container groups in the specified NGroups resource. Compute resources will be allocated and billing will start.

EXEC azure.container_instance.n_groups.start 
@resource_group_name='{{ resource_group_name }}' --required,
@ngroups_name='{{ ngroups_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;