Setting Up a Repository

  • 19 April 2021
  • 0 replies

This article applies to YAML blueprints. For details on blueprints defined in Terraform modules, see Using Terraform Blueprints in Torque, and for Helm blueprints, see Using Helm Blueprints in Torque.

The repository is a GitHub/BitBucket/GitLab repository where you keep the blueprint definition files and configurations. The repository can host YAML as well as Helm blueprint files.

  • The Helm blueprint files consist of your Helm charts, which can reside directly under the repository’s root folder or in any folder hierarchy within the root.
  • The YAML blueprint files are arranged under dedicated subfolders within the repository, as explained in the YAML Repository’s Structure section that follows, and include blueprint, application and service definition files, as well as scripts and additional assets, such as configuration and health check scripts. 

Each space in Torque is associated with such a repository. Torque reads the blueprints from the repository, validates them and exposes them in the blueprint catalog.

The repository defines two types of blueprints - sandbox and production environments. Note that it is possible to specify the same repository for both types (see Environment type indication for details).


In this article: 

The YAML repository's structure

The repository must be structured in a certain way so that Torque will be able to read and use it.

The repository should look something like this:

The repository has three main folders: blueprintsapplications and services.

IMPORTANT: These three folders' names are case-sensitive and must be in lowercase letters.

  • blueprints contains blueprint's YAML files. To learn more about the content of the YAML files see The Blueprint's YAML File
  • applications contains the applications you modeled. Each application is stored in its own subfolder and includes relevant application YAML files and optional deployment scripts. To learn more about the application's YAML file see The Application's YAML File

    Applications can optionally include additional scripts that run as part of deploying and configuring applications in a sandbox. Learn more about Application Scripts.

  • services contains YAMLs that define managed infrastructure services, which you can optionally include in your blueprint. Each service is stored in its own subfolder and includes relevant service YAML and terraform files. To learn more about defining services in Torque, see Integrating Cloud Services.

Setting up your repository

This section explains how to set up and connect your repository to Torque.

To add a Repository to your space:

  1. In GitHub/BitBucket/GitLab, create a repository. Copy the repository's URL. 
    We recommend you create a repository by forking the sample repository (in the Sample space).
  2. In  Torque perform the following steps:
    1. Access your space.
    2. Open the Settings page.
    3. Click the Repositories tab.
      You can set two different repositories in the space, one for sandbox environments and another for production environments. For details, about these types of environments, see Sandbox vs. Production Environments.
    4. Click Add a Repository.
      The Select your version control service dialog box is displayed.
    5. Select the source control tool you wish to use (GitHubBitBucket or GitLab) and paste the copied URL.
    6. Click Connect
    7. Authorize Torque's access to your GitHub/BitBucket/GitLab repository.

Your repository is now set up. You can now launch sandboxes out of the blueprints in your repository using Torque.

NOTE: It is also possible to launch sandboxes out of the repository's branches using the API. For details, contact Torque Support.

0 replies

Be the first to reply!