Azure Native v1.102.0, May 2 23
Azure Native v1.102.0, May 2 23
azure-native.securityinsights.SourceControl
Explore with Pulumi AI
Represents a SourceControl in Azure Security Insights. API Version: 2021-03-01-preview.
Example Usage
Creates a source control.
using System.Collections.Generic;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var sourceControl = new AzureNative.SecurityInsights.SourceControl("sourceControl", new()
{
ContentTypes = new[]
{
"AnalyticRules",
"Workbook",
},
Description = "This is a source control",
DisplayName = "My Source Control",
OperationalInsightsResourceProvider = "Microsoft.OperationalInsights",
RepoType = "Github",
Repository = new AzureNative.SecurityInsights.Inputs.RepositoryArgs
{
Branch = "master",
DisplayUrl = "https://github.com/user/repo",
PathMapping = new[]
{
new AzureNative.SecurityInsights.Inputs.ContentPathMapArgs
{
ContentType = "AnalyticRules",
Path = "path/to/rules",
},
new AzureNative.SecurityInsights.Inputs.ContentPathMapArgs
{
ContentType = "Workbook",
Path = "path/to/workbooks",
},
},
Url = "https://github.com/user/repo",
},
ResourceGroupName = "myRg",
SourceControlId = "789e0c1f-4a3d-43ad-809c-e713b677b04a",
WorkspaceName = "myWorkspace",
});
});
package main
import (
securityinsights "github.com/pulumi/pulumi-azure-native/sdk/go/azure/securityinsights"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := securityinsights.NewSourceControl(ctx, "sourceControl", &securityinsights.SourceControlArgs{
ContentTypes: pulumi.StringArray{
pulumi.String("AnalyticRules"),
pulumi.String("Workbook"),
},
Description: pulumi.String("This is a source control"),
DisplayName: pulumi.String("My Source Control"),
OperationalInsightsResourceProvider: pulumi.String("Microsoft.OperationalInsights"),
RepoType: pulumi.String("Github"),
Repository: securityinsights.RepositoryResponse{
Branch: pulumi.String("master"),
DisplayUrl: pulumi.String("https://github.com/user/repo"),
PathMapping: securityinsights.ContentPathMapArray{
&securityinsights.ContentPathMapArgs{
ContentType: pulumi.String("AnalyticRules"),
Path: pulumi.String("path/to/rules"),
},
&securityinsights.ContentPathMapArgs{
ContentType: pulumi.String("Workbook"),
Path: pulumi.String("path/to/workbooks"),
},
},
Url: pulumi.String("https://github.com/user/repo"),
},
ResourceGroupName: pulumi.String("myRg"),
SourceControlId: pulumi.String("789e0c1f-4a3d-43ad-809c-e713b677b04a"),
WorkspaceName: pulumi.String("myWorkspace"),
})
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.securityinsights.SourceControl;
import com.pulumi.azurenative.securityinsights.SourceControlArgs;
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 sourceControl = new SourceControl("sourceControl", SourceControlArgs.builder()
.contentTypes(
"AnalyticRules",
"Workbook")
.description("This is a source control")
.displayName("My Source Control")
.operationalInsightsResourceProvider("Microsoft.OperationalInsights")
.repoType("Github")
.repository(Map.ofEntries(
Map.entry("branch", "master"),
Map.entry("displayUrl", "https://github.com/user/repo"),
Map.entry("pathMapping",
Map.ofEntries(
Map.entry("contentType", "AnalyticRules"),
Map.entry("path", "path/to/rules")
),
Map.ofEntries(
Map.entry("contentType", "Workbook"),
Map.entry("path", "path/to/workbooks")
)),
Map.entry("url", "https://github.com/user/repo")
))
.resourceGroupName("myRg")
.sourceControlId("789e0c1f-4a3d-43ad-809c-e713b677b04a")
.workspaceName("myWorkspace")
.build());
}
}
import pulumi
import pulumi_azure_native as azure_native
source_control = azure_native.securityinsights.SourceControl("sourceControl",
content_types=[
"AnalyticRules",
"Workbook",
],
description="This is a source control",
display_name="My Source Control",
operational_insights_resource_provider="Microsoft.OperationalInsights",
repo_type="Github",
repository=azure_native.securityinsights.RepositoryResponseArgs(
branch="master",
display_url="https://github.com/user/repo",
path_mapping=[
azure_native.securityinsights.ContentPathMapArgs(
content_type="AnalyticRules",
path="path/to/rules",
),
azure_native.securityinsights.ContentPathMapArgs(
content_type="Workbook",
path="path/to/workbooks",
),
],
url="https://github.com/user/repo",
),
resource_group_name="myRg",
source_control_id="789e0c1f-4a3d-43ad-809c-e713b677b04a",
workspace_name="myWorkspace")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";
const sourceControl = new azure_native.securityinsights.SourceControl("sourceControl", {
contentTypes: [
"AnalyticRules",
"Workbook",
],
description: "This is a source control",
displayName: "My Source Control",
operationalInsightsResourceProvider: "Microsoft.OperationalInsights",
repoType: "Github",
repository: {
branch: "master",
displayUrl: "https://github.com/user/repo",
pathMapping: [
{
contentType: "AnalyticRules",
path: "path/to/rules",
},
{
contentType: "Workbook",
path: "path/to/workbooks",
},
],
url: "https://github.com/user/repo",
},
resourceGroupName: "myRg",
sourceControlId: "789e0c1f-4a3d-43ad-809c-e713b677b04a",
workspaceName: "myWorkspace",
});
resources:
sourceControl:
type: azure-native:securityinsights:SourceControl
properties:
contentTypes:
- AnalyticRules
- Workbook
description: This is a source control
displayName: My Source Control
operationalInsightsResourceProvider: Microsoft.OperationalInsights
repoType: Github
repository:
branch: master
displayUrl: https://github.com/user/repo
pathMapping:
- contentType: AnalyticRules
path: path/to/rules
- contentType: Workbook
path: path/to/workbooks
url: https://github.com/user/repo
resourceGroupName: myRg
sourceControlId: 789e0c1f-4a3d-43ad-809c-e713b677b04a
workspaceName: myWorkspace
Create SourceControl Resource
new SourceControl(name: string, args: SourceControlArgs, opts?: CustomResourceOptions);
@overload
def SourceControl(resource_name: str,
opts: Optional[ResourceOptions] = None,
content_types: Optional[Sequence[Union[str, ContentType]]] = None,
created_at: Optional[str] = None,
created_by: Optional[str] = None,
created_by_type: Optional[Union[str, CreatedByType]] = None,
description: Optional[str] = None,
display_name: Optional[str] = None,
id: Optional[str] = None,
last_modified_at: Optional[str] = None,
last_modified_by: Optional[str] = None,
last_modified_by_type: Optional[Union[str, CreatedByType]] = None,
operational_insights_resource_provider: Optional[str] = None,
repo_type: Optional[Union[str, RepoType]] = None,
repository: Optional[RepositoryArgs] = None,
resource_group_name: Optional[str] = None,
source_control_id: Optional[str] = None,
workspace_name: Optional[str] = None)
@overload
def SourceControl(resource_name: str,
args: SourceControlArgs,
opts: Optional[ResourceOptions] = None)
func NewSourceControl(ctx *Context, name string, args SourceControlArgs, opts ...ResourceOption) (*SourceControl, error)
public SourceControl(string name, SourceControlArgs args, CustomResourceOptions? opts = null)
public SourceControl(String name, SourceControlArgs args)
public SourceControl(String name, SourceControlArgs args, CustomResourceOptions options)
type: azure-native:securityinsights:SourceControl
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SourceControlArgs
- 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 SourceControlArgs
- 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 SourceControlArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SourceControlArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SourceControlArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
SourceControl 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 SourceControl resource accepts the following input properties:
- Content
Types List<Union<string, Pulumi.Azure Native. Security Insights. Content Type>> Array of source control content types.
- Display
Name string The display name of the source control
- Operational
Insights stringResource Provider The namespace of workspaces resource provider- Microsoft.OperationalInsights.
- Repo
Type string | Pulumi.Azure Native. Security Insights. Repo Type The repository type of the source control
- Repository
Pulumi.
Azure Native. Security Insights. Inputs. Repository Args Repository metadata.
- Resource
Group stringName The name of the resource group. The name is case insensitive.
- Workspace
Name string The name of the workspace.
- Created
At string The timestamp of resource creation (UTC).
- Created
By string The identity that created the resource.
- Created
By string | Pulumi.Type Azure Native. Security Insights. Created By Type The type of identity that created the resource.
- Description string
A description of the source control
- Id string
The id (a Guid) of the source control
- Last
Modified stringAt The timestamp of resource last modification (UTC)
- Last
Modified stringBy The identity that last modified the resource.
- Last
Modified string | Pulumi.By Type Azure Native. Security Insights. Created By Type The type of identity that last modified the resource.
- Source
Control stringId Source control Id
- Content
Types []string Array of source control content types.
- Display
Name string The display name of the source control
- Operational
Insights stringResource Provider The namespace of workspaces resource provider- Microsoft.OperationalInsights.
- Repo
Type string | RepoType The repository type of the source control
- Repository
Repository
Args Repository metadata.
- Resource
Group stringName The name of the resource group. The name is case insensitive.
- Workspace
Name string The name of the workspace.
- Created
At string The timestamp of resource creation (UTC).
- Created
By string The identity that created the resource.
- Created
By string | CreatedType By Type The type of identity that created the resource.
- Description string
A description of the source control
- Id string
The id (a Guid) of the source control
- Last
Modified stringAt The timestamp of resource last modification (UTC)
- Last
Modified stringBy The identity that last modified the resource.
- Last
Modified string | CreatedBy Type By Type The type of identity that last modified the resource.
- Source
Control stringId Source control Id
- content
Types List<Either<String,ContentType>> Array of source control content types.
- display
Name String The display name of the source control
- operational
Insights StringResource Provider The namespace of workspaces resource provider- Microsoft.OperationalInsights.
- repo
Type String | RepoType The repository type of the source control
- repository
Repository
Args Repository metadata.
- resource
Group StringName The name of the resource group. The name is case insensitive.
- workspace
Name String The name of the workspace.
- created
At String The timestamp of resource creation (UTC).
- created
By String The identity that created the resource.
- created
By String | CreatedType By Type The type of identity that created the resource.
- description String
A description of the source control
- id String
The id (a Guid) of the source control
- last
Modified StringAt The timestamp of resource last modification (UTC)
- last
Modified StringBy The identity that last modified the resource.
- last
Modified String | CreatedBy Type By Type The type of identity that last modified the resource.
- source
Control StringId Source control Id
- content
Types (string | ContentType)[] Array of source control content types.
- display
Name string The display name of the source control
- operational
Insights stringResource Provider The namespace of workspaces resource provider- Microsoft.OperationalInsights.
- repo
Type string | RepoType The repository type of the source control
- repository
Repository
Args Repository metadata.
- resource
Group stringName The name of the resource group. The name is case insensitive.
- workspace
Name string The name of the workspace.
- created
At string The timestamp of resource creation (UTC).
- created
By string The identity that created the resource.
- created
By string | CreatedType By Type The type of identity that created the resource.
- description string
A description of the source control
- id string
The id (a Guid) of the source control
- last
Modified stringAt The timestamp of resource last modification (UTC)
- last
Modified stringBy The identity that last modified the resource.
- last
Modified string | CreatedBy Type By Type The type of identity that last modified the resource.
- source
Control stringId Source control Id
- content_
types Sequence[Union[str, ContentType]] Array of source control content types.
- display_
name str The display name of the source control
- operational_
insights_ strresource_ provider The namespace of workspaces resource provider- Microsoft.OperationalInsights.
- repo_
type str | RepoType The repository type of the source control
- repository
Repository
Args Repository metadata.
- resource_
group_ strname The name of the resource group. The name is case insensitive.
- workspace_
name str The name of the workspace.
- created_
at str The timestamp of resource creation (UTC).
- created_
by str The identity that created the resource.
- created_
by_ str | Createdtype By Type The type of identity that created the resource.
- description str
A description of the source control
- id str
The id (a Guid) of the source control
- last_
modified_ strat The timestamp of resource last modification (UTC)
- last_
modified_ strby The identity that last modified the resource.
- last_
modified_ str | Createdby_ type By Type The type of identity that last modified the resource.
- source_
control_ strid Source control Id
- content
Types List<String | "AnalyticRule" | "Workbook"> Array of source control content types.
- display
Name String The display name of the source control
- operational
Insights StringResource Provider The namespace of workspaces resource provider- Microsoft.OperationalInsights.
- repo
Type String | "Github" | "DevOps" The repository type of the source control
- repository Property Map
Repository metadata.
- resource
Group StringName The name of the resource group. The name is case insensitive.
- workspace
Name String The name of the workspace.
- created
At String The timestamp of resource creation (UTC).
- created
By String The identity that created the resource.
- created
By String | "User" | "Application" | "ManagedType Identity" | "Key" The type of identity that created the resource.
- description String
A description of the source control
- id String
The id (a Guid) of the source control
- last
Modified StringAt The timestamp of resource last modification (UTC)
- last
Modified StringBy The identity that last modified the resource.
- last
Modified String | "User" | "Application" | "ManagedBy Type Identity" | "Key" The type of identity that last modified the resource.
- source
Control StringId Source control Id
Outputs
All input properties are implicitly available as output properties. Additionally, the SourceControl resource produces the following output properties:
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
Azure resource name
- System
Data Pulumi.Azure Native. Security Insights. Outputs. System Data Response Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
Azure resource type
- Etag string
Etag of the azure resource
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
Azure resource name
- System
Data SystemData Response Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
Azure resource type
- Etag string
Etag of the azure resource
- id String
The provider-assigned unique ID for this managed resource.
- name String
Azure resource name
- system
Data SystemData Response Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
Azure resource type
- etag String
Etag of the azure resource
- id string
The provider-assigned unique ID for this managed resource.
- name string
Azure resource name
- system
Data SystemData Response Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type string
Azure resource type
- etag string
Etag of the azure resource
- id str
The provider-assigned unique ID for this managed resource.
- name str
Azure resource name
- system_
data SystemData Response Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type str
Azure resource type
- etag str
Etag of the azure resource
- id String
The provider-assigned unique ID for this managed resource.
- name String
Azure resource name
- system
Data Property Map Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
Azure resource type
- etag String
Etag of the azure resource
Supporting Types
ContentPathMap
- Content
Type string | Pulumi.Azure Native. Security Insights. Content Type Content type.
- Path string
The path to the content.
- Content
Type string | ContentType Content type.
- Path string
The path to the content.
- content
Type String | ContentType Content type.
- path String
The path to the content.
- content
Type string | ContentType Content type.
- path string
The path to the content.
- content_
type str | ContentType Content type.
- path str
The path to the content.
- content
Type String | "AnalyticRule" | "Workbook" Content type.
- path String
The path to the content.
ContentPathMapResponse
- Content
Type string Content type.
- Path string
The path to the content.
- Content
Type string Content type.
- Path string
The path to the content.
- content
Type String Content type.
- path String
The path to the content.
- content
Type string Content type.
- path string
The path to the content.
- content_
type str Content type.
- path str
The path to the content.
- content
Type String Content type.
- path String
The path to the content.
ContentType
- Analytic
Rule - AnalyticRule
- Workbook
- Workbook
- Content
Type Analytic Rule - AnalyticRule
- Content
Type Workbook - Workbook
- Analytic
Rule - AnalyticRule
- Workbook
- Workbook
- Analytic
Rule - AnalyticRule
- Workbook
- Workbook
- ANALYTIC_RULE
- AnalyticRule
- WORKBOOK
- Workbook
- "Analytic
Rule" - AnalyticRule
- "Workbook"
- Workbook
CreatedByType
- User
- User
- Application
- Application
- Managed
Identity - ManagedIdentity
- Key
- Key
- Created
By Type User - User
- Created
By Type Application - Application
- Created
By Type Managed Identity - ManagedIdentity
- Created
By Type Key - Key
- User
- User
- Application
- Application
- Managed
Identity - ManagedIdentity
- Key
- Key
- User
- User
- Application
- Application
- Managed
Identity - ManagedIdentity
- Key
- Key
- USER
- User
- APPLICATION
- Application
- MANAGED_IDENTITY
- ManagedIdentity
- KEY
- Key
- "User"
- User
- "Application"
- Application
- "Managed
Identity" - ManagedIdentity
- "Key"
- Key
RepoType
- Github
- Github
- Dev
Ops - DevOps
- Repo
Type Github - Github
- Repo
Type Dev Ops - DevOps
- Github
- Github
- Dev
Ops - DevOps
- Github
- Github
- Dev
Ops - DevOps
- GITHUB
- Github
- DEV_OPS
- DevOps
- "Github"
- Github
- "Dev
Ops" - DevOps
Repository
- Branch string
Branch name of repository.
- Deployment
Logs stringUrl Url to access repository action logs.
- Display
Url string Display url of repository.
- Path
Mapping List<Pulumi.Azure Native. Security Insights. Inputs. Content Path Map> Dictionary of source control content type and path mapping.
- Url string
Url of repository.
- Branch string
Branch name of repository.
- Deployment
Logs stringUrl Url to access repository action logs.
- Display
Url string Display url of repository.
- Path
Mapping []ContentPath Map Dictionary of source control content type and path mapping.
- Url string
Url of repository.
- branch String
Branch name of repository.
- deployment
Logs StringUrl Url to access repository action logs.
- display
Url String Display url of repository.
- path
Mapping List<ContentPath Map> Dictionary of source control content type and path mapping.
- url String
Url of repository.
- branch string
Branch name of repository.
- deployment
Logs stringUrl Url to access repository action logs.
- display
Url string Display url of repository.
- path
Mapping ContentPath Map[] Dictionary of source control content type and path mapping.
- url string
Url of repository.
- branch str
Branch name of repository.
- deployment_
logs_ strurl Url to access repository action logs.
- display_
url str Display url of repository.
- path_
mapping Sequence[ContentPath Map] Dictionary of source control content type and path mapping.
- url str
Url of repository.
- branch String
Branch name of repository.
- deployment
Logs StringUrl Url to access repository action logs.
- display
Url String Display url of repository.
- path
Mapping List<Property Map> Dictionary of source control content type and path mapping.
- url String
Url of repository.
RepositoryResponse
- Branch string
Branch name of repository.
- Deployment
Logs stringUrl Url to access repository action logs.
- Display
Url string Display url of repository.
- Path
Mapping List<Pulumi.Azure Native. Security Insights. Inputs. Content Path Map Response> Dictionary of source control content type and path mapping.
- Url string
Url of repository.
- Branch string
Branch name of repository.
- Deployment
Logs stringUrl Url to access repository action logs.
- Display
Url string Display url of repository.
- Path
Mapping []ContentPath Map Response Dictionary of source control content type and path mapping.
- Url string
Url of repository.
- branch String
Branch name of repository.
- deployment
Logs StringUrl Url to access repository action logs.
- display
Url String Display url of repository.
- path
Mapping List<ContentPath Map Response> Dictionary of source control content type and path mapping.
- url String
Url of repository.
- branch string
Branch name of repository.
- deployment
Logs stringUrl Url to access repository action logs.
- display
Url string Display url of repository.
- path
Mapping ContentPath Map Response[] Dictionary of source control content type and path mapping.
- url string
Url of repository.
- branch str
Branch name of repository.
- deployment_
logs_ strurl Url to access repository action logs.
- display_
url str Display url of repository.
- path_
mapping Sequence[ContentPath Map Response] Dictionary of source control content type and path mapping.
- url str
Url of repository.
- branch String
Branch name of repository.
- deployment
Logs StringUrl Url to access repository action logs.
- display
Url String Display url of repository.
- path
Mapping List<Property Map> Dictionary of source control content type and path mapping.
- url String
Url of repository.
SystemDataResponse
- Created
At string The timestamp of resource creation (UTC).
- Created
By string The identity that created the resource.
- Created
By stringType The type of identity that created the resource.
- Last
Modified stringAt The timestamp of resource last modification (UTC)
- Last
Modified stringBy The identity that last modified the resource.
- Last
Modified stringBy Type The type of identity that last modified the resource.
- Created
At string The timestamp of resource creation (UTC).
- Created
By string The identity that created the resource.
- Created
By stringType The type of identity that created the resource.
- Last
Modified stringAt The timestamp of resource last modification (UTC)
- Last
Modified stringBy The identity that last modified the resource.
- Last
Modified stringBy Type The type of identity that last modified the resource.
- created
At String The timestamp of resource creation (UTC).
- created
By String The identity that created the resource.
- created
By StringType The type of identity that created the resource.
- last
Modified StringAt The timestamp of resource last modification (UTC)
- last
Modified StringBy The identity that last modified the resource.
- last
Modified StringBy Type The type of identity that last modified the resource.
- created
At string The timestamp of resource creation (UTC).
- created
By string The identity that created the resource.
- created
By stringType The type of identity that created the resource.
- last
Modified stringAt The timestamp of resource last modification (UTC)
- last
Modified stringBy The identity that last modified the resource.
- last
Modified stringBy Type The type of identity that last modified the resource.
- created_
at str The timestamp of resource creation (UTC).
- created_
by str The identity that created the resource.
- created_
by_ strtype The type of identity that created the resource.
- last_
modified_ strat The timestamp of resource last modification (UTC)
- last_
modified_ strby The identity that last modified the resource.
- last_
modified_ strby_ type The type of identity that last modified the resource.
- created
At String The timestamp of resource creation (UTC).
- created
By String The identity that created the resource.
- created
By StringType The type of identity that created the resource.
- last
Modified StringAt The timestamp of resource last modification (UTC)
- last
Modified StringBy The identity that last modified the resource.
- last
Modified StringBy Type The type of identity that last modified the resource.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:securityinsights:SourceControl 789e0c1f-4a3d-43ad-809c-e713b677b04a /subscriptions/d0cfe6b2-9ac0-4464-9919-dccaee2e48c0/resourceGroups/myRg/providers/Microsoft.OperationalIinsights/workspaces/myWorkspace/providers/Microsoft.SecurityInsights/sourcecontrols/789e0c1f-4a3d-43ad-809c-e713b677b04a
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0