azure-native.sql.SyncAgent
Explore with Pulumi AI
An Azure SQL Database sync agent. API Version: 2020-11-01-preview.
Example Usage
Create a new sync agent
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var syncAgent = new AzureNative.Sql.SyncAgent("syncAgent", new()
{
ResourceGroupName = "syncagentcrud-65440",
ServerName = "syncagentcrud-8475",
SyncAgentName = "syncagentcrud-3187",
SyncDatabaseId = "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync",
});
});
package main
import (
sql "github.com/pulumi/pulumi-azure-native-sdk/sql"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := sql.NewSyncAgent(ctx, "syncAgent", &sql.SyncAgentArgs{
ResourceGroupName: pulumi.String("syncagentcrud-65440"),
ServerName: pulumi.String("syncagentcrud-8475"),
SyncAgentName: pulumi.String("syncagentcrud-3187"),
SyncDatabaseId: pulumi.String("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.sql.SyncAgent;
import com.pulumi.azurenative.sql.SyncAgentArgs;
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 syncAgent = new SyncAgent("syncAgent", SyncAgentArgs.builder()
.resourceGroupName("syncagentcrud-65440")
.serverName("syncagentcrud-8475")
.syncAgentName("syncagentcrud-3187")
.syncDatabaseId("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync")
.build());
}
}
import pulumi
import pulumi_azure_native as azure_native
sync_agent = azure_native.sql.SyncAgent("syncAgent",
resource_group_name="syncagentcrud-65440",
server_name="syncagentcrud-8475",
sync_agent_name="syncagentcrud-3187",
sync_database_id="/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const syncAgent = new azure_native.sql.SyncAgent("syncAgent", {
resourceGroupName: "syncagentcrud-65440",
serverName: "syncagentcrud-8475",
syncAgentName: "syncagentcrud-3187",
syncDatabaseId: "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync",
});
resources:
syncAgent:
type: azure-native:sql:SyncAgent
properties:
resourceGroupName: syncagentcrud-65440
serverName: syncagentcrud-8475
syncAgentName: syncagentcrud-3187
syncDatabaseId: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync
Update a sync agent
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var syncAgent = new AzureNative.Sql.SyncAgent("syncAgent", new()
{
ResourceGroupName = "syncagentcrud-65440",
ServerName = "syncagentcrud-8475",
SyncAgentName = "syncagentcrud-3187",
SyncDatabaseId = "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync",
});
});
package main
import (
sql "github.com/pulumi/pulumi-azure-native-sdk/sql"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := sql.NewSyncAgent(ctx, "syncAgent", &sql.SyncAgentArgs{
ResourceGroupName: pulumi.String("syncagentcrud-65440"),
ServerName: pulumi.String("syncagentcrud-8475"),
SyncAgentName: pulumi.String("syncagentcrud-3187"),
SyncDatabaseId: pulumi.String("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync"),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.sql.SyncAgent;
import com.pulumi.azurenative.sql.SyncAgentArgs;
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 syncAgent = new SyncAgent("syncAgent", SyncAgentArgs.builder()
.resourceGroupName("syncagentcrud-65440")
.serverName("syncagentcrud-8475")
.syncAgentName("syncagentcrud-3187")
.syncDatabaseId("/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync")
.build());
}
}
import pulumi
import pulumi_azure_native as azure_native
sync_agent = azure_native.sql.SyncAgent("syncAgent",
resource_group_name="syncagentcrud-65440",
server_name="syncagentcrud-8475",
sync_agent_name="syncagentcrud-3187",
sync_database_id="/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const syncAgent = new azure_native.sql.SyncAgent("syncAgent", {
resourceGroupName: "syncagentcrud-65440",
serverName: "syncagentcrud-8475",
syncAgentName: "syncagentcrud-3187",
syncDatabaseId: "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync",
});
resources:
syncAgent:
type: azure-native:sql:SyncAgent
properties:
resourceGroupName: syncagentcrud-65440
serverName: syncagentcrud-8475
syncAgentName: syncagentcrud-3187
syncDatabaseId: /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/databases/sync
Create SyncAgent Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SyncAgent(name: string, args: SyncAgentArgs, opts?: CustomResourceOptions);
@overload
def SyncAgent(resource_name: str,
args: SyncAgentArgs,
opts: Optional[ResourceOptions] = None)
@overload
def SyncAgent(resource_name: str,
opts: Optional[ResourceOptions] = None,
resource_group_name: Optional[str] = None,
server_name: Optional[str] = None,
sync_agent_name: Optional[str] = None,
sync_database_id: Optional[str] = None)
func NewSyncAgent(ctx *Context, name string, args SyncAgentArgs, opts ...ResourceOption) (*SyncAgent, error)
public SyncAgent(string name, SyncAgentArgs args, CustomResourceOptions? opts = null)
public SyncAgent(String name, SyncAgentArgs args)
public SyncAgent(String name, SyncAgentArgs args, CustomResourceOptions options)
type: azure-native:sql:SyncAgent
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 SyncAgentArgs
- 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 SyncAgentArgs
- 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 SyncAgentArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SyncAgentArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SyncAgentArgs
- 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 syncAgentResource = new AzureNative.Sql.SyncAgent("syncAgentResource", new()
{
ResourceGroupName = "string",
ServerName = "string",
SyncAgentName = "string",
SyncDatabaseId = "string",
});
example, err := sql.NewSyncAgent(ctx, "syncAgentResource", &sql.SyncAgentArgs{
ResourceGroupName: "string",
ServerName: "string",
SyncAgentName: "string",
SyncDatabaseId: "string",
})
var syncAgentResource = new SyncAgent("syncAgentResource", SyncAgentArgs.builder()
.resourceGroupName("string")
.serverName("string")
.syncAgentName("string")
.syncDatabaseId("string")
.build());
sync_agent_resource = azure_native.sql.SyncAgent("syncAgentResource",
resource_group_name=string,
server_name=string,
sync_agent_name=string,
sync_database_id=string)
const syncAgentResource = new azure_native.sql.SyncAgent("syncAgentResource", {
resourceGroupName: "string",
serverName: "string",
syncAgentName: "string",
syncDatabaseId: "string",
});
type: azure-native:sql:SyncAgent
properties:
resourceGroupName: string
serverName: string
syncAgentName: string
syncDatabaseId: string
SyncAgent Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The SyncAgent resource accepts the following input properties:
- Resource
Group stringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- Server
Name string - The name of the server on which the sync agent is hosted.
- Sync
Agent stringName - The name of the sync agent.
- Sync
Database stringId - ARM resource id of the sync database in the sync agent.
- Resource
Group stringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- Server
Name string - The name of the server on which the sync agent is hosted.
- Sync
Agent stringName - The name of the sync agent.
- Sync
Database stringId - ARM resource id of the sync database in the sync agent.
- resource
Group StringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server
Name String - The name of the server on which the sync agent is hosted.
- sync
Agent StringName - The name of the sync agent.
- sync
Database StringId - ARM resource id of the sync database in the sync agent.
- resource
Group stringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server
Name string - The name of the server on which the sync agent is hosted.
- sync
Agent stringName - The name of the sync agent.
- sync
Database stringId - ARM resource id of the sync database in the sync agent.
- resource_
group_ strname - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server_
name str - The name of the server on which the sync agent is hosted.
- sync_
agent_ strname - The name of the sync agent.
- sync_
database_ strid - ARM resource id of the sync database in the sync agent.
- resource
Group StringName - The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.
- server
Name String - The name of the server on which the sync agent is hosted.
- sync
Agent StringName - The name of the sync agent.
- sync
Database StringId - ARM resource id of the sync database in the sync agent.
Outputs
All input properties are implicitly available as output properties. Additionally, the SyncAgent resource produces the following output properties:
- Expiry
Time string - Expiration time of the sync agent version.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Up boolTo Date - If the sync agent version is up to date.
- Last
Alive stringTime - Last alive time of the sync agent.
- Name string
- Resource name.
- State string
- State of the sync agent.
- Type string
- Resource type.
- Version string
- Version of the sync agent.
- Expiry
Time string - Expiration time of the sync agent version.
- Id string
- The provider-assigned unique ID for this managed resource.
- Is
Up boolTo Date - If the sync agent version is up to date.
- Last
Alive stringTime - Last alive time of the sync agent.
- Name string
- Resource name.
- State string
- State of the sync agent.
- Type string
- Resource type.
- Version string
- Version of the sync agent.
- expiry
Time String - Expiration time of the sync agent version.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Up BooleanTo Date - If the sync agent version is up to date.
- last
Alive StringTime - Last alive time of the sync agent.
- name String
- Resource name.
- state String
- State of the sync agent.
- type String
- Resource type.
- version String
- Version of the sync agent.
- expiry
Time string - Expiration time of the sync agent version.
- id string
- The provider-assigned unique ID for this managed resource.
- is
Up booleanTo Date - If the sync agent version is up to date.
- last
Alive stringTime - Last alive time of the sync agent.
- name string
- Resource name.
- state string
- State of the sync agent.
- type string
- Resource type.
- version string
- Version of the sync agent.
- expiry_
time str - Expiration time of the sync agent version.
- id str
- The provider-assigned unique ID for this managed resource.
- is_
up_ boolto_ date - If the sync agent version is up to date.
- last_
alive_ strtime - Last alive time of the sync agent.
- name str
- Resource name.
- state str
- State of the sync agent.
- type str
- Resource type.
- version str
- Version of the sync agent.
- expiry
Time String - Expiration time of the sync agent version.
- id String
- The provider-assigned unique ID for this managed resource.
- is
Up BooleanTo Date - If the sync agent version is up to date.
- last
Alive StringTime - Last alive time of the sync agent.
- name String
- Resource name.
- state String
- State of the sync agent.
- type String
- Resource type.
- version String
- Version of the sync agent.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:sql:SyncAgent syncagent /subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/syncagentcrud-8475/syncAgents/syncagentcrud-3187
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- azure-native-v1 pulumi/pulumi-azure-native
- License
- Apache-2.0