1. Packages
  2. Vra Provider
  3. API Docs
  4. ContentSource
vra 0.15.0 published on Tuesday, Aug 19, 2025 by vmware

vra.ContentSource

Explore with Pulumi AI

vra logo
vra 0.15.0 published on Tuesday, Aug 19, 2025 by vmware

    This resource provides a way to create a content source VMware Aria Automation.

    Example Usage

    S

    import * as pulumi from "@pulumi/pulumi";
    import * as vra from "@pulumi/vra";
    
    const _this = new vra.ContentSource("this", {
        description: "Some content Source",
        projectId: _var.project_id,
        syncEnabled: false,
        typeId: "com.gitlab",
        config: {
            branch: "main",
            contentType: "BLUEPRINT",
            integrationId: _var.integration_id,
            repository: "vracontent/vra8_content_source_test",
            path: "blueprint01",
        },
    });
    
    import pulumi
    import pulumi_vra as vra
    
    this = vra.ContentSource("this",
        description="Some content Source",
        project_id=var["project_id"],
        sync_enabled=False,
        type_id="com.gitlab",
        config={
            "branch": "main",
            "content_type": "BLUEPRINT",
            "integration_id": var["integration_id"],
            "repository": "vracontent/vra8_content_source_test",
            "path": "blueprint01",
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vra/vra"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := vra.NewContentSource(ctx, "this", &vra.ContentSourceArgs{
    			Description: pulumi.String("Some content Source"),
    			ProjectId:   pulumi.Any(_var.Project_id),
    			SyncEnabled: pulumi.Bool(false),
    			TypeId:      pulumi.String("com.gitlab"),
    			Config: &vra.ContentSourceConfigArgs{
    				Branch:        pulumi.String("main"),
    				ContentType:   pulumi.String("BLUEPRINT"),
    				IntegrationId: pulumi.Any(_var.Integration_id),
    				Repository:    pulumi.String("vracontent/vra8_content_source_test"),
    				Path:          pulumi.String("blueprint01"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Vra = Pulumi.Vra;
    
    return await Deployment.RunAsync(() => 
    {
        var @this = new Vra.ContentSource("this", new()
        {
            Description = "Some content Source",
            ProjectId = @var.Project_id,
            SyncEnabled = false,
            TypeId = "com.gitlab",
            Config = new Vra.Inputs.ContentSourceConfigArgs
            {
                Branch = "main",
                ContentType = "BLUEPRINT",
                IntegrationId = @var.Integration_id,
                Repository = "vracontent/vra8_content_source_test",
                Path = "blueprint01",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.vra.ContentSource;
    import com.pulumi.vra.ContentSourceArgs;
    import com.pulumi.vra.inputs.ContentSourceConfigArgs;
    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 this_ = new ContentSource("this", ContentSourceArgs.builder()
                .description("Some content Source")
                .projectId(var_.project_id())
                .syncEnabled("false")
                .typeId("com.gitlab")
                .config(ContentSourceConfigArgs.builder()
                    .branch("main")
                    .contentType("BLUEPRINT")
                    .integrationId(var_.integration_id())
                    .repository("vracontent/vra8_content_source_test")
                    .path("blueprint01")
                    .build())
                .build());
    
        }
    }
    
    resources:
      this:
        type: vra:ContentSource
        properties:
          description: Some content Source
          projectId: ${var.project_id}
          syncEnabled: 'false'
          typeId: com.gitlab
          config:
            branch: main
            contentType: BLUEPRINT
            integrationId: ${var.integration_id}
            repository: vracontent/vra8_content_source_test
            path: blueprint01
    

    Create ContentSource Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new ContentSource(name: string, args: ContentSourceArgs, opts?: CustomResourceOptions);
    @overload
    def ContentSource(resource_name: str,
                      args: ContentSourceArgs,
                      opts: Optional[ResourceOptions] = None)
    
    @overload
    def ContentSource(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      config: Optional[ContentSourceConfigArgs] = None,
                      project_id: Optional[str] = None,
                      sync_enabled: Optional[bool] = None,
                      type_id: Optional[str] = None,
                      content_source_id: Optional[str] = None,
                      description: Optional[str] = None,
                      name: Optional[str] = None)
    func NewContentSource(ctx *Context, name string, args ContentSourceArgs, opts ...ResourceOption) (*ContentSource, error)
    public ContentSource(string name, ContentSourceArgs args, CustomResourceOptions? opts = null)
    public ContentSource(String name, ContentSourceArgs args)
    public ContentSource(String name, ContentSourceArgs args, CustomResourceOptions options)
    
    type: vra:ContentSource
    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 ContentSourceArgs
    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 ContentSourceArgs
    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 ContentSourceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ContentSourceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ContentSourceArgs
    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 contentSourceResource = new Vra.ContentSource("contentSourceResource", new()
    {
        Config = new Vra.Inputs.ContentSourceConfigArgs
        {
            Branch = "string",
            ContentType = "string",
            IntegrationId = "string",
            Repository = "string",
            Path = "string",
            ProjectName = "string",
        },
        ProjectId = "string",
        SyncEnabled = false,
        TypeId = "string",
        ContentSourceId = "string",
        Description = "string",
        Name = "string",
    });
    
    example, err := vra.NewContentSource(ctx, "contentSourceResource", &vra.ContentSourceArgs{
    	Config: &vra.ContentSourceConfigArgs{
    		Branch:        pulumi.String("string"),
    		ContentType:   pulumi.String("string"),
    		IntegrationId: pulumi.String("string"),
    		Repository:    pulumi.String("string"),
    		Path:          pulumi.String("string"),
    		ProjectName:   pulumi.String("string"),
    	},
    	ProjectId:       pulumi.String("string"),
    	SyncEnabled:     pulumi.Bool(false),
    	TypeId:          pulumi.String("string"),
    	ContentSourceId: pulumi.String("string"),
    	Description:     pulumi.String("string"),
    	Name:            pulumi.String("string"),
    })
    
    var contentSourceResource = new ContentSource("contentSourceResource", ContentSourceArgs.builder()
        .config(ContentSourceConfigArgs.builder()
            .branch("string")
            .contentType("string")
            .integrationId("string")
            .repository("string")
            .path("string")
            .projectName("string")
            .build())
        .projectId("string")
        .syncEnabled(false)
        .typeId("string")
        .contentSourceId("string")
        .description("string")
        .name("string")
        .build());
    
    content_source_resource = vra.ContentSource("contentSourceResource",
        config={
            "branch": "string",
            "content_type": "string",
            "integration_id": "string",
            "repository": "string",
            "path": "string",
            "project_name": "string",
        },
        project_id="string",
        sync_enabled=False,
        type_id="string",
        content_source_id="string",
        description="string",
        name="string")
    
    const contentSourceResource = new vra.ContentSource("contentSourceResource", {
        config: {
            branch: "string",
            contentType: "string",
            integrationId: "string",
            repository: "string",
            path: "string",
            projectName: "string",
        },
        projectId: "string",
        syncEnabled: false,
        typeId: "string",
        contentSourceId: "string",
        description: "string",
        name: "string",
    });
    
    type: vra:ContentSource
    properties:
        config:
            branch: string
            contentType: string
            integrationId: string
            path: string
            projectName: string
            repository: string
        contentSourceId: string
        description: string
        name: string
        projectId: string
        syncEnabled: false
        typeId: string
    

    ContentSource 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 ContentSource resource accepts the following input properties:

    Config ContentSourceConfig
    The content source custom configuration.
    ProjectId string
    The id of the project this entity belongs to.
    SyncEnabled bool
    Wether or not sync is enabled for this content source.
    TypeId string
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    ContentSourceId string
    Description string
    A human-friendly description for the content source instance.
    Name string
    The name of the content source instance.
    Config ContentSourceConfigArgs
    The content source custom configuration.
    ProjectId string
    The id of the project this entity belongs to.
    SyncEnabled bool
    Wether or not sync is enabled for this content source.
    TypeId string
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    ContentSourceId string
    Description string
    A human-friendly description for the content source instance.
    Name string
    The name of the content source instance.
    config ContentSourceConfig
    The content source custom configuration.
    projectId String
    The id of the project this entity belongs to.
    syncEnabled Boolean
    Wether or not sync is enabled for this content source.
    typeId String
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    contentSourceId String
    description String
    A human-friendly description for the content source instance.
    name String
    The name of the content source instance.
    config ContentSourceConfig
    The content source custom configuration.
    projectId string
    The id of the project this entity belongs to.
    syncEnabled boolean
    Wether or not sync is enabled for this content source.
    typeId string
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    contentSourceId string
    description string
    A human-friendly description for the content source instance.
    name string
    The name of the content source instance.
    config ContentSourceConfigArgs
    The content source custom configuration.
    project_id str
    The id of the project this entity belongs to.
    sync_enabled bool
    Wether or not sync is enabled for this content source.
    type_id str
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    content_source_id str
    description str
    A human-friendly description for the content source instance.
    name str
    The name of the content source instance.
    config Property Map
    The content source custom configuration.
    projectId String
    The id of the project this entity belongs to.
    syncEnabled Boolean
    Wether or not sync is enabled for this content source.
    typeId String
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    contentSourceId String
    description String
    A human-friendly description for the content source instance.
    name String
    The name of the content source instance.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ContentSource resource produces the following output properties:

    CreatedAt string
    Date when the entity was created. The date is in ISO 8601 and UTC.
    CreatedBy string
    The user the entity was created by.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdatedAt string
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    LastUpdatedBy string
    The user the entity was last updated by.
    OrgId string
    The id of the organization this entity belongs to.
    CreatedAt string
    Date when the entity was created. The date is in ISO 8601 and UTC.
    CreatedBy string
    The user the entity was created by.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdatedAt string
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    LastUpdatedBy string
    The user the entity was last updated by.
    OrgId string
    The id of the organization this entity belongs to.
    createdAt String
    Date when the entity was created. The date is in ISO 8601 and UTC.
    createdBy String
    The user the entity was created by.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt String
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    lastUpdatedBy String
    The user the entity was last updated by.
    orgId String
    The id of the organization this entity belongs to.
    createdAt string
    Date when the entity was created. The date is in ISO 8601 and UTC.
    createdBy string
    The user the entity was created by.
    id string
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt string
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    lastUpdatedBy string
    The user the entity was last updated by.
    orgId string
    The id of the organization this entity belongs to.
    created_at str
    Date when the entity was created. The date is in ISO 8601 and UTC.
    created_by str
    The user the entity was created by.
    id str
    The provider-assigned unique ID for this managed resource.
    last_updated_at str
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    last_updated_by str
    The user the entity was last updated by.
    org_id str
    The id of the organization this entity belongs to.
    createdAt String
    Date when the entity was created. The date is in ISO 8601 and UTC.
    createdBy String
    The user the entity was created by.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt String
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    lastUpdatedBy String
    The user the entity was last updated by.
    orgId String
    The id of the organization this entity belongs to.

    Look up Existing ContentSource Resource

    Get an existing ContentSource 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?: ContentSourceState, opts?: CustomResourceOptions): ContentSource
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            config: Optional[ContentSourceConfigArgs] = None,
            content_source_id: Optional[str] = None,
            created_at: Optional[str] = None,
            created_by: Optional[str] = None,
            description: Optional[str] = None,
            last_updated_at: Optional[str] = None,
            last_updated_by: Optional[str] = None,
            name: Optional[str] = None,
            org_id: Optional[str] = None,
            project_id: Optional[str] = None,
            sync_enabled: Optional[bool] = None,
            type_id: Optional[str] = None) -> ContentSource
    func GetContentSource(ctx *Context, name string, id IDInput, state *ContentSourceState, opts ...ResourceOption) (*ContentSource, error)
    public static ContentSource Get(string name, Input<string> id, ContentSourceState? state, CustomResourceOptions? opts = null)
    public static ContentSource get(String name, Output<String> id, ContentSourceState state, CustomResourceOptions options)
    resources:  _:    type: vra:ContentSource    get:      id: ${id}
    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.
    The following state arguments are supported:
    Config ContentSourceConfig
    The content source custom configuration.
    ContentSourceId string
    CreatedAt string
    Date when the entity was created. The date is in ISO 8601 and UTC.
    CreatedBy string
    The user the entity was created by.
    Description string
    A human-friendly description for the content source instance.
    LastUpdatedAt string
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    LastUpdatedBy string
    The user the entity was last updated by.
    Name string
    The name of the content source instance.
    OrgId string
    The id of the organization this entity belongs to.
    ProjectId string
    The id of the project this entity belongs to.
    SyncEnabled bool
    Wether or not sync is enabled for this content source.
    TypeId string
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    Config ContentSourceConfigArgs
    The content source custom configuration.
    ContentSourceId string
    CreatedAt string
    Date when the entity was created. The date is in ISO 8601 and UTC.
    CreatedBy string
    The user the entity was created by.
    Description string
    A human-friendly description for the content source instance.
    LastUpdatedAt string
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    LastUpdatedBy string
    The user the entity was last updated by.
    Name string
    The name of the content source instance.
    OrgId string
    The id of the organization this entity belongs to.
    ProjectId string
    The id of the project this entity belongs to.
    SyncEnabled bool
    Wether or not sync is enabled for this content source.
    TypeId string
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    config ContentSourceConfig
    The content source custom configuration.
    contentSourceId String
    createdAt String
    Date when the entity was created. The date is in ISO 8601 and UTC.
    createdBy String
    The user the entity was created by.
    description String
    A human-friendly description for the content source instance.
    lastUpdatedAt String
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    lastUpdatedBy String
    The user the entity was last updated by.
    name String
    The name of the content source instance.
    orgId String
    The id of the organization this entity belongs to.
    projectId String
    The id of the project this entity belongs to.
    syncEnabled Boolean
    Wether or not sync is enabled for this content source.
    typeId String
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    config ContentSourceConfig
    The content source custom configuration.
    contentSourceId string
    createdAt string
    Date when the entity was created. The date is in ISO 8601 and UTC.
    createdBy string
    The user the entity was created by.
    description string
    A human-friendly description for the content source instance.
    lastUpdatedAt string
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    lastUpdatedBy string
    The user the entity was last updated by.
    name string
    The name of the content source instance.
    orgId string
    The id of the organization this entity belongs to.
    projectId string
    The id of the project this entity belongs to.
    syncEnabled boolean
    Wether or not sync is enabled for this content source.
    typeId string
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    config ContentSourceConfigArgs
    The content source custom configuration.
    content_source_id str
    created_at str
    Date when the entity was created. The date is in ISO 8601 and UTC.
    created_by str
    The user the entity was created by.
    description str
    A human-friendly description for the content source instance.
    last_updated_at str
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    last_updated_by str
    The user the entity was last updated by.
    name str
    The name of the content source instance.
    org_id str
    The id of the organization this entity belongs to.
    project_id str
    The id of the project this entity belongs to.
    sync_enabled bool
    Wether or not sync is enabled for this content source.
    type_id str
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.
    config Property Map
    The content source custom configuration.
    contentSourceId String
    createdAt String
    Date when the entity was created. The date is in ISO 8601 and UTC.
    createdBy String
    The user the entity was created by.
    description String
    A human-friendly description for the content source instance.
    lastUpdatedAt String
    Date when the entity was last updated. The date is ISO 8601 and UTC.
    lastUpdatedBy String
    The user the entity was last updated by.
    name String
    The name of the content source instance.
    orgId String
    The id of the organization this entity belongs to.
    projectId String
    The id of the project this entity belongs to.
    syncEnabled Boolean
    Wether or not sync is enabled for this content source.
    typeId String
    The type of this content source. Supported values are com.gitlab, com.github, org.bitbucket.

    Supporting Types

    ContentSourceConfig, ContentSourceConfigArgs

    Branch string
    The content source branch name.
    ContentType string
    The content source type. Supported values are BLUEPRINT, IMAGE, ABX_SCRIPTS, TERRAFORM_CONFIGURATION.
    IntegrationId string
    The content source integration id as seen integrations.
    Repository string
    The content source repository.
    Path string
    Path to refer to in the content source repository and branch.
    ProjectName string
    The name of the project.
    Branch string
    The content source branch name.
    ContentType string
    The content source type. Supported values are BLUEPRINT, IMAGE, ABX_SCRIPTS, TERRAFORM_CONFIGURATION.
    IntegrationId string
    The content source integration id as seen integrations.
    Repository string
    The content source repository.
    Path string
    Path to refer to in the content source repository and branch.
    ProjectName string
    The name of the project.
    branch String
    The content source branch name.
    contentType String
    The content source type. Supported values are BLUEPRINT, IMAGE, ABX_SCRIPTS, TERRAFORM_CONFIGURATION.
    integrationId String
    The content source integration id as seen integrations.
    repository String
    The content source repository.
    path String
    Path to refer to in the content source repository and branch.
    projectName String
    The name of the project.
    branch string
    The content source branch name.
    contentType string
    The content source type. Supported values are BLUEPRINT, IMAGE, ABX_SCRIPTS, TERRAFORM_CONFIGURATION.
    integrationId string
    The content source integration id as seen integrations.
    repository string
    The content source repository.
    path string
    Path to refer to in the content source repository and branch.
    projectName string
    The name of the project.
    branch str
    The content source branch name.
    content_type str
    The content source type. Supported values are BLUEPRINT, IMAGE, ABX_SCRIPTS, TERRAFORM_CONFIGURATION.
    integration_id str
    The content source integration id as seen integrations.
    repository str
    The content source repository.
    path str
    Path to refer to in the content source repository and branch.
    project_name str
    The name of the project.
    branch String
    The content source branch name.
    contentType String
    The content source type. Supported values are BLUEPRINT, IMAGE, ABX_SCRIPTS, TERRAFORM_CONFIGURATION.
    integrationId String
    The content source integration id as seen integrations.
    repository String
    The content source repository.
    path String
    Path to refer to in the content source repository and branch.
    projectName String
    The name of the project.

    Import

    Content source can be imported using the id, e.g.

    $ pulumi import vra:index/contentSource:ContentSource this 05956583-6488-4e7d-84c9-92a7b7219a15`
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    vra vmware/terraform-provider-vra
    License
    Notes
    This Pulumi package is based on the vra Terraform Provider.
    vra logo
    vra 0.15.0 published on Tuesday, Aug 19, 2025 by vmware