InfraDots logo
Documentation

Version Control System (VCS) Providers

Version Control System (VCS) providers allow you to connect your InfraDots workspaces to your source code repositories.

What are VCS Providers?

VCS providers in InfraDots Platform enable you to:

  • Connect workspaces to git repositories containing IaC configurations
  • Automatically trigger runs when changes are pushed to your repository
  • Track which code changes triggered which infrastructure changes
  • Enable GitOps workflows for your infrastructure

Supported VCS Providers

InfraDots currently supports the following VCS providers:

  • GitHub: Connect to public and private repositories on GitHub.com
  • GitHub Enterprise: Connect to repositories on your self-hosted GitHub Enterprise instance
  • GitLab: Connect to public and private repositories on GitLab.com
  • GitLab Enterprise/Community Edition: Connect to repositories on your self-hosted GitLab instance

Connecting a VCS Provider

GitHub

  1. Navigate to your organization's settings
  2. Select the "VCS Providers" tab
  3. Click "Add VCS Provider"
  4. Select "GitHub"
  5. On GitHub.com, register a new OAuth Application with the following information:
    • Application Name: InfraDots (your-organization-name)
    • Homepage URL: Your InfraDots platform URL
    • Application description: Any description of your choice
    • Authorization callback URL: The callback URL provided by InfraDots
  6. After registering the application, you'll be taken to the new application's page
  7. Enter the Client ID in the InfraDots form
  8. Generate a new client secret on GitHub and enter it in the InfraDots form
  9. Click "Connect and Continue"
  10. You will be redirected to GitHub to authorize the application
  11. After authorization, you'll be redirected back to InfraDots with the connection established

GitLab

  1. Navigate to your organization's settings
  2. Select the "VCS Providers" tab
  3. Click "Add VCS Provider"
  4. Select "GitLab"
  5. On GitLab.com, navigate to User Settings → Applications and register a new OAuth Application with the following information:
    • Name: InfraDots (your-organization-name)
    • Redirect URI: The callback URL provided by InfraDots
    • Scopes: Only select "api"
  6. After clicking "Save application", you'll be taken to the new application's page
  7. Enter the Application ID and Secret in the InfraDots form
  8. Click "Connect and Continue"
  9. You will be redirected to GitLab to authorize the application
  10. After authorization, you'll be redirected back to InfraDots with the connection established

Managing VCS Connections

Viewing Connected Providers

  1. Navigate to your organization's settings
  2. Select the "VCS Providers" tab
  3. View the list of connected VCS providers

Removing a VCS Provider

  1. Navigate to your organization's settings
  2. Select the "VCS Providers" tab
  3. Find the VCS provider you want to remove
  4. Click the delete icon
  5. Confirm the deletion

Updating VCS Provider Settings

If you need to update your VCS provider settings:

  1. Remove the existing VCS provider connection
  2. Add a new VCS provider with the updated settings

VCS-Driven Workflow

Developer ──▶ Git Push ──▶ GitHub/GitLab
                                │
                           Webhook Event
                                │
                                ▼
                         InfraDots Platform
                                │
                    ┌───────────┴───────────┐
                    ▼                       ▼
              Terraform Plan          IDP Agent Review
                    │                       │
                    └───────────┬───────────┘
                                ▼
                         Apply (if approved)

Plan Comments on Pull Requests

When a plan for a pull request finishes, InfraDots posts what it found on the pull request itself, so reviewers see the change where they are already looking:

InfraDots plan — acme-prod

2 to add, 1 to change, 0 to destroy

- create  aws_s3_bucket.logs
- update  aws_iam_role.deploy
- create  aws_instance.api

Waiting for approval · View run · abc1234
  • One comment per workspace, updated in place. Every push to the pull request edits the same comment rather than adding a new one. If a repository has several workspaces, each gets its own. If someone deletes the comment, the next plan posts a fresh one.
  • Only the newest plan. If two pushes finish out of order, the older plan never overwrites the newer one. The commit the plan was made for is shown at the end of the comment.
  • Long plans are trimmed. The first 20 resources are listed, followed by a count of the rest and a link to the full plan in InfraDots.
  • Sensitive values stay out. The comment is built from InfraDots' masked, structured summary of the plan, never from the raw plan output.
  • Pull requests only. Runs triggered by a push to the default branch, by a schedule, or by drift detection are not commented on. A plan that fails is reported through the status check rather than a comment.

InfraDots needs permission to comment on pull requests in the connected repository. If it doesn't have it, the run is unaffected and the comment is simply skipped.

Turning plan comments off

Plan comments are on by default. To turn them off, set pr_plan_comments to false on the organization to stop them everywhere, or on a single workspace to opt just that one out. A workspace setting takes precedence over the organization's, and a workspace that hasn't set it follows the organization.

Using VCS with Workspaces

Once you've connected a VCS provider, you can use it with your workspaces:

  1. When creating a new workspace, select "Version Control Workflow"
  2. Choose the VCS provider you want to use
  3. Select the repository and branch containing your Terraform configuration
  4. Configure any additional settings
  5. Create the workspace

The workspace will now be connected to your VCS repository. Any changes pushed to the specified branch will trigger a new run in the workspace.

💡 Tip

[!tip] For GitHub, you can use a GitHub App instead of an OAuth app for more granular repository access control.

Troubleshooting VCS Connections

If you encounter issues with your VCS connection:

  • Ensure the OAuth application has the correct permissions
  • Verify the callback URL is correctly configured
  • Check that your access token hasn't expired
  • Ensure your repository exists and is accessible to the OAuth application
  • Verify that the specified branch exists in the repository