You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The gitlab_repository_file resource allows to manage the lifecycle of a file within a repository.
7
-
~> Limitations: The GitLab Repository Files API https://docs.gitlab.com/ee/api/repository_files.html can only create, update or delete a single file at the time. The API will also fail with a 400 https://docs.gitlab.com/ee/api/repository_files.html#update-existing-file-in-repository response status code if the underlying repository is changed while the API tries to make changes. Therefore, it's recommended to make sure that you execute it with -parallelism=1 https://www.terraform.io/docs/cli/commands/apply.html#parallelism-n and that no other entity than the terraform at hand makes changes to the underlying repository while it's executing.
7
+
-> Timeouts Default timeout for Create, Update and Delete is one minute and can be configured in the timeouts block.
8
+
-> Implementation Detail GitLab is unable to handle concurrent calls to the GitLab repository files API for the same project.
9
+
Therefore, this resource queues every call to the repository files API no matter of the project, which may slow down the terraform
10
+
execution time for some configurations. In addition, retries are performed in case a refresh is required because another application
11
+
changed the repository at the same time.
8
12
Upstream API: GitLab REST API docs https://docs.gitlab.com/ee/api/repository_files.html
9
13
---
10
14
11
15
# gitlab_repository_file (Resource)
12
16
13
17
The `gitlab_repository_file` resource allows to manage the lifecycle of a file within a repository.
14
18
15
-
~> **Limitations**: The [GitLab Repository Files API](https://docs.gitlab.com/ee/api/repository_files.html) can only create, update or delete a single file at the time. The API will also [fail with a 400](https://docs.gitlab.com/ee/api/repository_files.html#update-existing-file-in-repository) response status code if the underlying repository is changed while the API tries to make changes. Therefore, it's recommended to make sure that you execute it with [-parallelism=1](https://www.terraform.io/docs/cli/commands/apply.html#parallelism-n) and that no other entity than the terraform at hand makes changes to the underlying repository while it's executing.
19
+
-> **Timeouts** Default timeout for *Create*, *Update* and *Delete* is one minute and can be configured in the `timeouts` block.
20
+
21
+
-> **Implementation Detail** GitLab is unable to handle concurrent calls to the GitLab repository files API for the same project.
22
+
Therefore, this resource queues every call to the repository files API no matter of the project, which may slow down the terraform
23
+
execution time for some configurations. In addition, retries are performed in case a refresh is required because another application
24
+
changed the repository at the same time.
16
25
17
26
**Upstream API**: [GitLab REST API docs](https://docs.gitlab.com/ee/api/repository_files.html)
Description: `The `+"`gitlab_repository_file`"+` resource allows to manage the lifecycle of a file within a repository.
20
37
21
-
~> **Limitations**: The [GitLab Repository Files API](https://docs.gitlab.com/ee/api/repository_files.html) can only create, update or delete a single file at the time. The API will also [fail with a 400](https://docs.gitlab.com/ee/api/repository_files.html#update-existing-file-in-repository) response status code if the underlying repository is changed while the API tries to make changes. Therefore, it's recommended to make sure that you execute it with [-parallelism=1](https://www.terraform.io/docs/cli/commands/apply.html#parallelism-n) and that no other entity than the terraform at hand makes changes to the underlying repository while it's executing.
38
+
-> **Timeouts** Default timeout for *Create*, *Update* and *Delete* is one minute and can be configured in the `+"`timeouts`"+` block.
39
+
40
+
-> **Implementation Detail** GitLab is unable to handle concurrent calls to the GitLab repository files API for the same project.
41
+
Therefore, this resource queues every call to the repository files API no matter of the project, which may slow down the terraform
42
+
execution time for some configurations. In addition, retries are performed in case a refresh is required because another application
43
+
changed the repository at the same time.
22
44
23
45
**Upstream API**: [GitLab REST API docs](https://docs.gitlab.com/ee/api/repository_files.html)`,
0 commit comments