Skip to content

Group variable and project variable not support raw property

Hi: We are using terraform GitLab provider to manage the group variables and project variables, based on the GitLab API here: https://docs.gitlab.com/ee/api/group_level_variables.html It's support raw property. But somehow in terraform GitLab provider, seems like not support this property yet: https://registry.terraform.io/providers/gitlabhq/gitlab/latest/docs/resources/project_variable

thanks!

Implementation Guide

As described above GitLab recently introduced a raw field to the variables API. This applies to the project-, group- and instance-variables and their corresponding provider resources and data sources.

go-gitlab already supports a Raw field in the project and group variable API, but not in the instance variable API.

  1. Implement the Raw field in the go-gitlab instance variable interface, see https://github.com/xanzy/go-gitlab/pull/1682
  2. Implement the raw attribute in the provider project, group and variable resources (just follow the same implementation pattern as for other attributes)

Feel free to split the above implementation into multiple MRs.

Edited by Timo Furrer