GitLab API icon

GitLab API

Gitlab

Actions880

Overview

This node operation uploads a Terraform module file to a specific project in GitLab's Terraform Registry. It is useful for automating the publishing of Terraform module versions directly to GitLab, facilitating infrastructure as code workflows. For example, a DevOps engineer can use this node to programmatically upload new versions of Terraform modules to a GitLab project repository.

Use Case Examples

  1. Uploading a new version of a Terraform module file to a GitLab project for version management and distribution.
  2. Automating Terraform module publishing as part of a CI/CD pipeline.

Properties

Name Meaning
Skip Authentication Option to skip authentication for the request.
Authentication Type of authentication used, defaulting to GitLab API key authentication.
baseUrl Base URL of the GitLab instance, default is https://gitlab.com.
Method HTTP method to use for the request, default is GET. For this operation, PUT is typically used.
Path Parameters Parameters to specify the project ID or full path, module name, and module system for the Terraform module to upload.

Output

JSON

  • id - The ID or full path of the project where the module is uploaded.
  • module_name - The name of the Terraform module.
  • module_system - The system type of the Terraform module.
  • module_version - The version of the Terraform module being uploaded.
  • file - The Terraform module file that is uploaded.

Dependencies

  • GitLab API key credential for authentication

Troubleshooting

  • Ensure the project ID or full path is correct to avoid 404 errors.
  • Verify the module name and system parameters match the expected values in GitLab.
  • Check that the file to upload is correctly formatted and accessible.
  • Authentication errors may occur if the API key is missing or invalid; ensure proper credentials are set.

Links

Discussion