GitLab API

GitlabTool

Actions1000

Overview

This node interacts with the GitLab API to retrieve a specific Terraform module file from the Terraform Registry. It is designed to fetch module files based on parameters such as module namespace, module name, module system, and module version. This is useful for automating infrastructure as code workflows, where you need to programmatically access Terraform module files stored in GitLab's Terraform Registry.

Use Case Examples

  1. Automatically download a specific version of a Terraform module file for deployment automation.
  2. Integrate Terraform module retrieval into CI/CD pipelines to ensure the correct module version is used.

Properties

Name Meaning
Skip Authentication Option to skip authentication when making the API request.
Authentication Type of authentication used for the API request, defaulting to GitLab API authentication.
baseUrl Base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the API request, default is GET.
Query Parameters Query parameters for the API request, specifically the module version to retrieve.
Path Parameters Path parameters for the API request including module namespace, module name, and module system.

Output

JSON

  • fileContent - The content of the Terraform module file retrieved from the GitLab Terraform Registry.

Dependencies

  • GitLab API authentication token

Troubleshooting

  • Ensure the module namespace, name, system, and version are correctly specified to avoid 404 errors.
  • Check authentication credentials if receiving authorization errors.
  • Verify the base URL is correct if connecting to a self-hosted GitLab instance.

Links

Discussion