project-provisioner
donaldrich80/project-provisioner/gitlab
Terraform module for configuring and maintaining your Gitlab repositories and Gitlab-CI pipelines.
terraform-gitlab-project-provisioner About This module is designed to codify the features, settings, branches, environmental variables, accessibility, and build pipelines of Gitlab projects using the Hashicorp provider. In addition to being able to provision new projects, it also useful for ensuring standardized and immutable settings to all of your projects quickly and easily. Parameters that were formerly set project by project, can now be set on a global basis. Use Cases - Provisioning a newly created self-hosted GitLab instance prior to uploading code - Simplified method to manage/update repositories on either self-hosted or Gitlab.com Functionality General project settings Container registry, wiki, issues, etc Merge/branch settings Branches Declare an arbitrary number of branches, wit
| Name | Type | Description | Default |
|---|---|---|---|
| default_branch | string | The default branch for the project | "master" |
| cron_timezone | string | Timezone for Cron scheduled pipelines | "America/Chicago" |
| protected_branches | map | Map of project names to configuration. | {
"master": {
"merge_access_level" |
| snippets_enabled | bool | Enable snippets for the project | false |
| merge_method | string | Merge method to use on merge requests | "merge" |
| only_allow_merge_if_pipeline_succeeds | bool | Set to true if you want allow merges only if a pipeline succeeds | true |
| name | string | The name of the project | "name" |
| path | string | Numeric project ID | "path" |
| description | string | A description of the project | "Managed by Terraform" |
| remove_source_branch_after_merge | bool | Whether to remove a branch after its merged | true |
| container_registry_enabled | bool | Enable container registry for the project | false |
| initialize_with_readme | bool | Create master branch with first commit containing a README.md file | false |
| packages_enabled | bool | Enable packages for the project | false |
| request_access_enabled | bool | Allow users to request member access | false |
| shared_runners_enabled | bool | Enable shared runners for this project | false |
| pipelines_enabled | bool | Enable pipelines for this project | true |
| only_allow_merge_if_all_discussions_are_resolved | bool | Set to true if you want allow merges only if all discussions are resolved | true |
| visibility_level | string | Set to public to create a public project. Valid values are private, internal, pu | "private" |
| wiki_enabled | bool | Enable wiki for the project | false |
| scheduled_pipelines | map | Map of scheduled_pipelines to configuration. | {} |
gitlab_project_id — Id of created GitLab project