newrelic.cloud.AzureLinkAccount
Explore with Pulumi AI
Use this resource to link an Azure account to New Relic.
Prerequisite
Some configuration is required in Azure for the New Relic Azure cloud integrations to be able to pull data.
To start receiving Azure data with New Relic Azure integrations, connect your Azure account to New Relic infrastructure monitoring. If you don’t have one already, create a New Relic account. It’s free, forever.
Setup is required in Azure for this resource to work properly. You can find instructions on how to set up Azure on our documentation.
Example Usage
You can also use the full example, including the Azure set up, found in our guides.
import * as pulumi from "@pulumi/pulumi";
import * as newrelic from "@pulumi/newrelic";
const foo = new newrelic.cloud.AzureLinkAccount("foo", {
accountId: "The New Relic account ID where you want to link the Azure account",
applicationId: "ID of the application",
clientSecret: "Secret value of client's Azure account",
subscriptionId: "Subscription ID of Azure",
tenantId: "Tenant ID of the Azure",
name: "Name of the linked account",
});
import pulumi
import pulumi_newrelic as newrelic
foo = newrelic.cloud.AzureLinkAccount("foo",
account_id="The New Relic account ID where you want to link the Azure account",
application_id="ID of the application",
client_secret="Secret value of client's Azure account",
subscription_id="Subscription ID of Azure",
tenant_id="Tenant ID of the Azure",
name="Name of the linked account")
package main
import (
"github.com/pulumi/pulumi-newrelic/sdk/v5/go/newrelic/cloud"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := cloud.NewAzureLinkAccount(ctx, "foo", &cloud.AzureLinkAccountArgs{
AccountId: pulumi.String("The New Relic account ID where you want to link the Azure account"),
ApplicationId: pulumi.String("ID of the application"),
ClientSecret: pulumi.String("Secret value of client's Azure account"),
SubscriptionId: pulumi.String("Subscription ID of Azure"),
TenantId: pulumi.String("Tenant ID of the Azure"),
Name: pulumi.String("Name of the linked account"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using NewRelic = Pulumi.NewRelic;
return await Deployment.RunAsync(() =>
{
var foo = new NewRelic.Cloud.AzureLinkAccount("foo", new()
{
AccountId = "The New Relic account ID where you want to link the Azure account",
ApplicationId = "ID of the application",
ClientSecret = "Secret value of client's Azure account",
SubscriptionId = "Subscription ID of Azure",
TenantId = "Tenant ID of the Azure",
Name = "Name of the linked account",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.newrelic.cloud.AzureLinkAccount;
import com.pulumi.newrelic.cloud.AzureLinkAccountArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var foo = new AzureLinkAccount("foo", AzureLinkAccountArgs.builder()
.accountId("The New Relic account ID where you want to link the Azure account")
.applicationId("ID of the application")
.clientSecret("Secret value of client's Azure account")
.subscriptionId("Subscription ID of Azure")
.tenantId("Tenant ID of the Azure")
.name("Name of the linked account")
.build());
}
}
resources:
foo:
type: newrelic:cloud:AzureLinkAccount
properties:
accountId: The New Relic account ID where you want to link the Azure account
applicationId: ID of the application
clientSecret: Secret value of client's Azure account
subscriptionId: Subscription ID of Azure
tenantId: Tenant ID of the Azure
name: Name of the linked account
Create AzureLinkAccount Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new AzureLinkAccount(name: string, args: AzureLinkAccountArgs, opts?: CustomResourceOptions);
@overload
def AzureLinkAccount(resource_name: str,
args: AzureLinkAccountArgs,
opts: Optional[ResourceOptions] = None)
@overload
def AzureLinkAccount(resource_name: str,
opts: Optional[ResourceOptions] = None,
application_id: Optional[str] = None,
client_secret: Optional[str] = None,
subscription_id: Optional[str] = None,
tenant_id: Optional[str] = None,
account_id: Optional[str] = None,
name: Optional[str] = None)
func NewAzureLinkAccount(ctx *Context, name string, args AzureLinkAccountArgs, opts ...ResourceOption) (*AzureLinkAccount, error)
public AzureLinkAccount(string name, AzureLinkAccountArgs args, CustomResourceOptions? opts = null)
public AzureLinkAccount(String name, AzureLinkAccountArgs args)
public AzureLinkAccount(String name, AzureLinkAccountArgs args, CustomResourceOptions options)
type: newrelic:cloud:AzureLinkAccount
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args AzureLinkAccountArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args AzureLinkAccountArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args AzureLinkAccountArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args AzureLinkAccountArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args AzureLinkAccountArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var azureLinkAccountResource = new NewRelic.Cloud.AzureLinkAccount("azureLinkAccountResource", new()
{
ApplicationId = "string",
ClientSecret = "string",
SubscriptionId = "string",
TenantId = "string",
AccountId = "string",
Name = "string",
});
example, err := cloud.NewAzureLinkAccount(ctx, "azureLinkAccountResource", &cloud.AzureLinkAccountArgs{
ApplicationId: pulumi.String("string"),
ClientSecret: pulumi.String("string"),
SubscriptionId: pulumi.String("string"),
TenantId: pulumi.String("string"),
AccountId: pulumi.String("string"),
Name: pulumi.String("string"),
})
var azureLinkAccountResource = new AzureLinkAccount("azureLinkAccountResource", AzureLinkAccountArgs.builder()
.applicationId("string")
.clientSecret("string")
.subscriptionId("string")
.tenantId("string")
.accountId("string")
.name("string")
.build());
azure_link_account_resource = newrelic.cloud.AzureLinkAccount("azureLinkAccountResource",
application_id="string",
client_secret="string",
subscription_id="string",
tenant_id="string",
account_id="string",
name="string")
const azureLinkAccountResource = new newrelic.cloud.AzureLinkAccount("azureLinkAccountResource", {
applicationId: "string",
clientSecret: "string",
subscriptionId: "string",
tenantId: "string",
accountId: "string",
name: "string",
});
type: newrelic:cloud:AzureLinkAccount
properties:
accountId: string
applicationId: string
clientSecret: string
name: string
subscriptionId: string
tenantId: string
AzureLinkAccount Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The AzureLinkAccount resource accepts the following input properties:
- Application
Id string - Application ID of the App.
- Client
Secret string - Secret Value of the client.
- Subscription
Id string - Subscription ID of the Azure cloud account.
- Tenant
Id string - Tenant ID of the Azure cloud account.
- Account
Id string - Account ID of the New Relic.
- Name string
- Name of the linked account
- Application
Id string - Application ID of the App.
- Client
Secret string - Secret Value of the client.
- Subscription
Id string - Subscription ID of the Azure cloud account.
- Tenant
Id string - Tenant ID of the Azure cloud account.
- Account
Id string - Account ID of the New Relic.
- Name string
- Name of the linked account
- application
Id String - Application ID of the App.
- client
Secret String - Secret Value of the client.
- subscription
Id String - Subscription ID of the Azure cloud account.
- tenant
Id String - Tenant ID of the Azure cloud account.
- account
Id String - Account ID of the New Relic.
- name String
- Name of the linked account
- application
Id string - Application ID of the App.
- client
Secret string - Secret Value of the client.
- subscription
Id string - Subscription ID of the Azure cloud account.
- tenant
Id string - Tenant ID of the Azure cloud account.
- account
Id string - Account ID of the New Relic.
- name string
- Name of the linked account
- application_
id str - Application ID of the App.
- client_
secret str - Secret Value of the client.
- subscription_
id str - Subscription ID of the Azure cloud account.
- tenant_
id str - Tenant ID of the Azure cloud account.
- account_
id str - Account ID of the New Relic.
- name str
- Name of the linked account
- application
Id String - Application ID of the App.
- client
Secret String - Secret Value of the client.
- subscription
Id String - Subscription ID of the Azure cloud account.
- tenant
Id String - Tenant ID of the Azure cloud account.
- account
Id String - Account ID of the New Relic.
- name String
- Name of the linked account
Outputs
All input properties are implicitly available as output properties. Additionally, the AzureLinkAccount resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing AzureLinkAccount Resource
Get an existing AzureLinkAccount resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: AzureLinkAccountState, opts?: CustomResourceOptions): AzureLinkAccount
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
account_id: Optional[str] = None,
application_id: Optional[str] = None,
client_secret: Optional[str] = None,
name: Optional[str] = None,
subscription_id: Optional[str] = None,
tenant_id: Optional[str] = None) -> AzureLinkAccount
func GetAzureLinkAccount(ctx *Context, name string, id IDInput, state *AzureLinkAccountState, opts ...ResourceOption) (*AzureLinkAccount, error)
public static AzureLinkAccount Get(string name, Input<string> id, AzureLinkAccountState? state, CustomResourceOptions? opts = null)
public static AzureLinkAccount get(String name, Output<String> id, AzureLinkAccountState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Account
Id string - Account ID of the New Relic.
- Application
Id string - Application ID of the App.
- Client
Secret string - Secret Value of the client.
- Name string
- Name of the linked account
- Subscription
Id string - Subscription ID of the Azure cloud account.
- Tenant
Id string - Tenant ID of the Azure cloud account.
- Account
Id string - Account ID of the New Relic.
- Application
Id string - Application ID of the App.
- Client
Secret string - Secret Value of the client.
- Name string
- Name of the linked account
- Subscription
Id string - Subscription ID of the Azure cloud account.
- Tenant
Id string - Tenant ID of the Azure cloud account.
- account
Id String - Account ID of the New Relic.
- application
Id String - Application ID of the App.
- client
Secret String - Secret Value of the client.
- name String
- Name of the linked account
- subscription
Id String - Subscription ID of the Azure cloud account.
- tenant
Id String - Tenant ID of the Azure cloud account.
- account
Id string - Account ID of the New Relic.
- application
Id string - Application ID of the App.
- client
Secret string - Secret Value of the client.
- name string
- Name of the linked account
- subscription
Id string - Subscription ID of the Azure cloud account.
- tenant
Id string - Tenant ID of the Azure cloud account.
- account_
id str - Account ID of the New Relic.
- application_
id str - Application ID of the App.
- client_
secret str - Secret Value of the client.
- name str
- Name of the linked account
- subscription_
id str - Subscription ID of the Azure cloud account.
- tenant_
id str - Tenant ID of the Azure cloud account.
- account
Id String - Account ID of the New Relic.
- application
Id String - Application ID of the App.
- client
Secret String - Secret Value of the client.
- name String
- Name of the linked account
- subscription
Id String - Subscription ID of the Azure cloud account.
- tenant
Id String - Tenant ID of the Azure cloud account.
Import
Linked Azure accounts can be imported using id
, you can find the id
of existing Azure linked accounts in Azure dashboard under Infrastructure in NewRelic
bash
$ pulumi import newrelic:cloud/azureLinkAccount:AzureLinkAccount foo <id>
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- New Relic pulumi/pulumi-newrelic
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
newrelic
Terraform Provider.