Project

Create a Project Resource

new Project(name: string, args?: ProjectArgs, opts?: CustomResourceOptions);
def Project(resource_name, opts=None, approvals_before_merge=None, archived=None, container_registry_enabled=None, default_branch=None, description=None, initialize_with_readme=None, issues_enabled=None, lfs_enabled=None, merge_method=None, merge_requests_enabled=None, name=None, namespace_id=None, only_allow_merge_if_all_discussions_are_resolved=None, only_allow_merge_if_pipeline_succeeds=None, path=None, pipelines_enabled=None, remove_source_branch_after_merge=None, request_access_enabled=None, shared_runners_enabled=None, shared_with_groups=None, snippets_enabled=None, tags=None, visibility_level=None, wiki_enabled=None, __props__=None);
func NewProject(ctx *Context, name string, args *ProjectArgs, opts ...ResourceOption) (*Project, error)
public Project(string name, ProjectArgs? args = null, CustomResourceOptions? opts = null)
name string
The unique name of the resource.
args ProjectArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args ProjectArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args ProjectArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

Project Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The Project resource accepts the following input properties:

ApprovalsBeforeMerge int

Number of merge request approvals required for merging. Default is 0.

Archived bool

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

ContainerRegistryEnabled bool

Enable container registry for the project.

DefaultBranch string

The default branch for the project.

Description string

A description of the project.

InitializeWithReadme bool

Create master branch with first commit containing a README.md file.

IssuesEnabled bool

Enable issue tracking for the project.

LfsEnabled bool

Enable LFS for the project.

MergeMethod string

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

MergeRequestsEnabled bool

Enable merge requests for the project.

Name string

The name of the project.

NamespaceId int

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

OnlyAllowMergeIfAllDiscussionsAreResolved bool

Set to true if you want allow merges only if all discussions are resolved.

OnlyAllowMergeIfPipelineSucceeds bool

Set to true if you want allow merges only if a pipeline succeeds.

Path string

The path of the repository.

PipelinesEnabled bool

Enable pipelines for the project.

RemoveSourceBranchAfterMerge bool

Enable Delete source branch option by default for all new merge requests.

RequestAccessEnabled bool

Allow users to request member access.

SharedRunnersEnabled bool

Enable shared runners for this project.

SharedWithGroups List<Pulumi.GitLab.Inputs.ProjectSharedWithGroupArgs>

Enable sharing the project with a list of groups (maps).

SnippetsEnabled bool

Enable snippets for the project.

Tags List<string>

Tags (topics) of the project.

VisibilityLevel string

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

WikiEnabled bool

Enable wiki for the project.

ApprovalsBeforeMerge int

Number of merge request approvals required for merging. Default is 0.

Archived bool

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

ContainerRegistryEnabled bool

Enable container registry for the project.

DefaultBranch string

The default branch for the project.

Description string

A description of the project.

InitializeWithReadme bool

Create master branch with first commit containing a README.md file.

IssuesEnabled bool

Enable issue tracking for the project.

LfsEnabled bool

Enable LFS for the project.

MergeMethod string

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

MergeRequestsEnabled bool

Enable merge requests for the project.

Name string

The name of the project.

NamespaceId int

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

OnlyAllowMergeIfAllDiscussionsAreResolved bool

Set to true if you want allow merges only if all discussions are resolved.

OnlyAllowMergeIfPipelineSucceeds bool

Set to true if you want allow merges only if a pipeline succeeds.

Path string

The path of the repository.

PipelinesEnabled bool

Enable pipelines for the project.

RemoveSourceBranchAfterMerge bool

Enable Delete source branch option by default for all new merge requests.

RequestAccessEnabled bool

Allow users to request member access.

SharedRunnersEnabled bool

Enable shared runners for this project.

SharedWithGroups []ProjectSharedWithGroup

Enable sharing the project with a list of groups (maps).

SnippetsEnabled bool

Enable snippets for the project.

Tags []string

Tags (topics) of the project.

VisibilityLevel string

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

WikiEnabled bool

Enable wiki for the project.

approvalsBeforeMerge number

Number of merge request approvals required for merging. Default is 0.

archived boolean

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

containerRegistryEnabled boolean

Enable container registry for the project.

defaultBranch string

The default branch for the project.

description string

A description of the project.

initializeWithReadme boolean

Create master branch with first commit containing a README.md file.

issuesEnabled boolean

Enable issue tracking for the project.

lfsEnabled boolean

Enable LFS for the project.

mergeMethod string

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

mergeRequestsEnabled boolean

Enable merge requests for the project.

name string

The name of the project.

namespaceId number

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

onlyAllowMergeIfAllDiscussionsAreResolved boolean

Set to true if you want allow merges only if all discussions are resolved.

onlyAllowMergeIfPipelineSucceeds boolean

Set to true if you want allow merges only if a pipeline succeeds.

path string

The path of the repository.

pipelinesEnabled boolean

Enable pipelines for the project.

removeSourceBranchAfterMerge boolean

Enable Delete source branch option by default for all new merge requests.

requestAccessEnabled boolean

Allow users to request member access.

sharedRunnersEnabled boolean

Enable shared runners for this project.

sharedWithGroups ProjectSharedWithGroup[]

Enable sharing the project with a list of groups (maps).

snippetsEnabled boolean

Enable snippets for the project.

tags string[]

Tags (topics) of the project.

visibilityLevel string

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

wikiEnabled boolean

Enable wiki for the project.

approvals_before_merge float

Number of merge request approvals required for merging. Default is 0.

archived bool

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

container_registry_enabled bool

Enable container registry for the project.

default_branch str

The default branch for the project.

description str

A description of the project.

initialize_with_readme bool

Create master branch with first commit containing a README.md file.

issues_enabled bool

Enable issue tracking for the project.

lfs_enabled bool

Enable LFS for the project.

merge_method str

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

merge_requests_enabled bool

Enable merge requests for the project.

name str

The name of the project.

namespace_id float

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

only_allow_merge_if_all_discussions_are_resolved bool

Set to true if you want allow merges only if all discussions are resolved.

only_allow_merge_if_pipeline_succeeds bool

Set to true if you want allow merges only if a pipeline succeeds.

path str

The path of the repository.

pipelines_enabled bool

Enable pipelines for the project.

remove_source_branch_after_merge bool

Enable Delete source branch option by default for all new merge requests.

request_access_enabled bool

Allow users to request member access.

shared_runners_enabled bool

Enable shared runners for this project.

shared_with_groups List[ProjectSharedWithGroup]

Enable sharing the project with a list of groups (maps).

snippets_enabled bool

Enable snippets for the project.

tags List[str]

Tags (topics) of the project.

visibility_level str

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

wiki_enabled bool

Enable wiki for the project.

Outputs

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

HttpUrlToRepo string

URL that can be provided to git clone to clone the repository via HTTP.

Id string
The provider-assigned unique ID for this managed resource.
RunnersToken string

Registration token to use during runner setup.

SshUrlToRepo string

URL that can be provided to git clone to clone the repository via SSH.

WebUrl string

URL that can be used to find the project in a browser.

HttpUrlToRepo string

URL that can be provided to git clone to clone the repository via HTTP.

Id string
The provider-assigned unique ID for this managed resource.
RunnersToken string

Registration token to use during runner setup.

SshUrlToRepo string

URL that can be provided to git clone to clone the repository via SSH.

WebUrl string

URL that can be used to find the project in a browser.

httpUrlToRepo string

URL that can be provided to git clone to clone the repository via HTTP.

id string
The provider-assigned unique ID for this managed resource.
runnersToken string

Registration token to use during runner setup.

sshUrlToRepo string

URL that can be provided to git clone to clone the repository via SSH.

webUrl string

URL that can be used to find the project in a browser.

http_url_to_repo str

URL that can be provided to git clone to clone the repository via HTTP.

id str
The provider-assigned unique ID for this managed resource.
runners_token str

Registration token to use during runner setup.

ssh_url_to_repo str

URL that can be provided to git clone to clone the repository via SSH.

web_url str

URL that can be used to find the project in a browser.

Look up an Existing Project Resource

Get an existing Project 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?: ProjectState, opts?: CustomResourceOptions): Project
static get(resource_name, id, opts=None, approvals_before_merge=None, archived=None, container_registry_enabled=None, default_branch=None, description=None, http_url_to_repo=None, initialize_with_readme=None, issues_enabled=None, lfs_enabled=None, merge_method=None, merge_requests_enabled=None, name=None, namespace_id=None, only_allow_merge_if_all_discussions_are_resolved=None, only_allow_merge_if_pipeline_succeeds=None, path=None, pipelines_enabled=None, remove_source_branch_after_merge=None, request_access_enabled=None, runners_token=None, shared_runners_enabled=None, shared_with_groups=None, snippets_enabled=None, ssh_url_to_repo=None, tags=None, visibility_level=None, web_url=None, wiki_enabled=None, __props__=None);
func GetProject(ctx *Context, name string, id IDInput, state *ProjectState, opts ...ResourceOption) (*Project, error)
public static Project Get(string name, Input<string> id, ProjectState? state, CustomResourceOptions? opts = null)
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.

The following state arguments are supported:

ApprovalsBeforeMerge int

Number of merge request approvals required for merging. Default is 0.

Archived bool

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

ContainerRegistryEnabled bool

Enable container registry for the project.

DefaultBranch string

The default branch for the project.

Description string

A description of the project.

HttpUrlToRepo string

URL that can be provided to git clone to clone the repository via HTTP.

InitializeWithReadme bool

Create master branch with first commit containing a README.md file.

IssuesEnabled bool

Enable issue tracking for the project.

LfsEnabled bool

Enable LFS for the project.

MergeMethod string

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

MergeRequestsEnabled bool

Enable merge requests for the project.

Name string

The name of the project.

NamespaceId int

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

OnlyAllowMergeIfAllDiscussionsAreResolved bool

Set to true if you want allow merges only if all discussions are resolved.

OnlyAllowMergeIfPipelineSucceeds bool

Set to true if you want allow merges only if a pipeline succeeds.

Path string

The path of the repository.

PipelinesEnabled bool

Enable pipelines for the project.

RemoveSourceBranchAfterMerge bool

Enable Delete source branch option by default for all new merge requests.

RequestAccessEnabled bool

Allow users to request member access.

RunnersToken string

Registration token to use during runner setup.

SharedRunnersEnabled bool

Enable shared runners for this project.

SharedWithGroups List<Pulumi.GitLab.Inputs.ProjectSharedWithGroupArgs>

Enable sharing the project with a list of groups (maps).

SnippetsEnabled bool

Enable snippets for the project.

SshUrlToRepo string

URL that can be provided to git clone to clone the repository via SSH.

Tags List<string>

Tags (topics) of the project.

VisibilityLevel string

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

WebUrl string

URL that can be used to find the project in a browser.

WikiEnabled bool

Enable wiki for the project.

ApprovalsBeforeMerge int

Number of merge request approvals required for merging. Default is 0.

Archived bool

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

ContainerRegistryEnabled bool

Enable container registry for the project.

DefaultBranch string

The default branch for the project.

Description string

A description of the project.

HttpUrlToRepo string

URL that can be provided to git clone to clone the repository via HTTP.

InitializeWithReadme bool

Create master branch with first commit containing a README.md file.

IssuesEnabled bool

Enable issue tracking for the project.

LfsEnabled bool

Enable LFS for the project.

MergeMethod string

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

MergeRequestsEnabled bool

Enable merge requests for the project.

Name string

The name of the project.

NamespaceId int

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

OnlyAllowMergeIfAllDiscussionsAreResolved bool

Set to true if you want allow merges only if all discussions are resolved.

OnlyAllowMergeIfPipelineSucceeds bool

Set to true if you want allow merges only if a pipeline succeeds.

Path string

The path of the repository.

PipelinesEnabled bool

Enable pipelines for the project.

RemoveSourceBranchAfterMerge bool

Enable Delete source branch option by default for all new merge requests.

RequestAccessEnabled bool

Allow users to request member access.

RunnersToken string

Registration token to use during runner setup.

SharedRunnersEnabled bool

Enable shared runners for this project.

SharedWithGroups []ProjectSharedWithGroup

Enable sharing the project with a list of groups (maps).

SnippetsEnabled bool

Enable snippets for the project.

SshUrlToRepo string

URL that can be provided to git clone to clone the repository via SSH.

Tags []string

Tags (topics) of the project.

VisibilityLevel string

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

WebUrl string

URL that can be used to find the project in a browser.

WikiEnabled bool

Enable wiki for the project.

approvalsBeforeMerge number

Number of merge request approvals required for merging. Default is 0.

archived boolean

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

containerRegistryEnabled boolean

Enable container registry for the project.

defaultBranch string

The default branch for the project.

description string

A description of the project.

httpUrlToRepo string

URL that can be provided to git clone to clone the repository via HTTP.

initializeWithReadme boolean

Create master branch with first commit containing a README.md file.

issuesEnabled boolean

Enable issue tracking for the project.

lfsEnabled boolean

Enable LFS for the project.

mergeMethod string

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

mergeRequestsEnabled boolean

Enable merge requests for the project.

name string

The name of the project.

namespaceId number

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

onlyAllowMergeIfAllDiscussionsAreResolved boolean

Set to true if you want allow merges only if all discussions are resolved.

onlyAllowMergeIfPipelineSucceeds boolean

Set to true if you want allow merges only if a pipeline succeeds.

path string

The path of the repository.

pipelinesEnabled boolean

Enable pipelines for the project.

removeSourceBranchAfterMerge boolean

Enable Delete source branch option by default for all new merge requests.

requestAccessEnabled boolean

Allow users to request member access.

runnersToken string

Registration token to use during runner setup.

sharedRunnersEnabled boolean

Enable shared runners for this project.

sharedWithGroups ProjectSharedWithGroup[]

Enable sharing the project with a list of groups (maps).

snippetsEnabled boolean

Enable snippets for the project.

sshUrlToRepo string

URL that can be provided to git clone to clone the repository via SSH.

tags string[]

Tags (topics) of the project.

visibilityLevel string

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

webUrl string

URL that can be used to find the project in a browser.

wikiEnabled boolean

Enable wiki for the project.

approvals_before_merge float

Number of merge request approvals required for merging. Default is 0.

archived bool

Whether the project is in read-only mode (archived). Repositories can be archived/unarchived by toggling this parameter.

container_registry_enabled bool

Enable container registry for the project.

default_branch str

The default branch for the project.

description str

A description of the project.

http_url_to_repo str

URL that can be provided to git clone to clone the repository via HTTP.

initialize_with_readme bool

Create master branch with first commit containing a README.md file.

issues_enabled bool

Enable issue tracking for the project.

lfs_enabled bool

Enable LFS for the project.

merge_method str

Set to ff to create fast-forward merges Valid values are merge, rebase_merge, ff Repositories are created with merge by default

merge_requests_enabled bool

Enable merge requests for the project.

name str

The name of the project.

namespace_id float

The namespace (group or user) of the project. Defaults to your user. See gitlab..Group for an example.

only_allow_merge_if_all_discussions_are_resolved bool

Set to true if you want allow merges only if all discussions are resolved.

only_allow_merge_if_pipeline_succeeds bool

Set to true if you want allow merges only if a pipeline succeeds.

path str

The path of the repository.

pipelines_enabled bool

Enable pipelines for the project.

remove_source_branch_after_merge bool

Enable Delete source branch option by default for all new merge requests.

request_access_enabled bool

Allow users to request member access.

runners_token str

Registration token to use during runner setup.

shared_runners_enabled bool

Enable shared runners for this project.

shared_with_groups List[ProjectSharedWithGroup]

Enable sharing the project with a list of groups (maps).

snippets_enabled bool

Enable snippets for the project.

ssh_url_to_repo str

URL that can be provided to git clone to clone the repository via SSH.

tags List[str]

Tags (topics) of the project.

visibility_level str

Set to public to create a public project. Valid values are private, internal, public. Repositories are created as private by default.

web_url str

URL that can be used to find the project in a browser.

wiki_enabled bool

Enable wiki for the project.

Supporting Types

ProjectSharedWithGroup

See the input and output API doc for this type.

See the input and output API doc for this type.

See the input and output API doc for this type.

GroupAccessLevel string

Group’s sharing permissions. See [group members permission][group_members_permissions] for more info. Valid values are guest, reporter, developer, master.

GroupId int

Group id of the group you want to share the project with.

GroupName string

Group’s name.

GroupAccessLevel string

Group’s sharing permissions. See [group members permission][group_members_permissions] for more info. Valid values are guest, reporter, developer, master.

GroupId int

Group id of the group you want to share the project with.

GroupName string

Group’s name.

groupAccessLevel string

Group’s sharing permissions. See [group members permission][group_members_permissions] for more info. Valid values are guest, reporter, developer, master.

groupId number

Group id of the group you want to share the project with.

groupName string

Group’s name.

groupAccessLevel str

Group’s sharing permissions. See [group members permission][group_members_permissions] for more info. Valid values are guest, reporter, developer, master.

group_id float

Group id of the group you want to share the project with.

groupName str

Group’s name.

Package Details

Repository
https://github.com/pulumi/pulumi-gitlab
License
Apache-2.0
Notes
This Pulumi package is based on the gitlab Terraform Provider.