Connect Your Repositories

How to Connect Repositories to retrieve artifacts.

Intro to Repositories

A Repository is used by a Component. A Repository acts as a source location for artifacts that will be deployed as Components. Each Component contains a pointer to where an artifact is stored in a Repository or on a file system. When DeployHub performs the pre-deployment steps, it retrieves the artifact from any location you specify. It pulls it from the Repository and creates a deployment package at deployment run time. For this reason, it does not need to store the actual artifact in the DeployHub versioning engine. Each Component is defined with a Repository reference. Your Repository can point to any type of repository such as Git, GitHub, Quay or binary repository such as Maven. A Repository can also reference a file system.

Container Repositories

You do not need to define a Repository if you only deploy containers. Containers are managed in “registries” which are handled differently than source code and file repositories. If you use a Container registry, DeployHub references this from within your Container Component definition. When you define your Component as a “Container” Component Type, you will enter the following container details:

  • container registry
  • container image
  • container digest
  • container tag

Use the Repository List View for Adding and Deleting

The Repository menu option is under the Advanced Features menu on the left of the DeployHub main panel. Select the Repository menu for a list of all Repositories to which you have access. The Search bar, represented by a funnel icon, filters Repositories based on Name or Domain.

The Repository List View has the following Tabs:

Tab Description
Refresh Refreshes the browser.
Add Allows you to Add a new Repository. Select from various pre-configured Repository Types. Each Type will determine the Details for that Repository.
Delete Deletes the selected item.

Double click on an item in the list to get the Dashboard view.

Use the Repository Dashboard for Viewing and Editing

The Dashboard view displays all information related to a specific Repository Type. Following are the Repository Types supported out-of-the-box:

  • HTTP
  • File System (included as a default with override and append options enabled)
  • OpenMake Meister (Build system with a binary repository)
  • SVN
  • Git (git repositories are treated as File System repositories). See GitHub for configuration steps.

Common Details of all Repositories Types

Field Description
Full Domain Name The fully qualified name of the Domain to which the Repository was defined.
Name The Name of the Repository.
Type The Repository Type chosen when you performed the Add.
Owner Type User or Group.
Owner Name of the Owner.
Summary A description of the Repository.
Created Auto-generated date when the Repository was added.
Modified Auto-generated date when the Repository was updated.
Credential The Credential used to access the Repository if required.

HTTP Repository Details

Field Description
URL The Universal Resource Locator used to locate the HTTP repository.
URL Encrypted Select the box to indicate the URL should be hidden in the database.
URL Override Select the box if the URL can be replaced at the Component definition.
Log File The fully qualified file name to the logs from the HTTP get.
Log File Encrypted Select the box to indicate the Log File name should be hidden in the database.
Log File Override Select the box if the Log File can be replaced at the Component definition.
Params Parameters used to invoke a RESTful API, allowing more detailed interaction with the HTTP Endpoint.
Params Encrypted Select the box to indicate the Parameters should be hidden in the database.
Params Override Select the box if the Parameters can be replaced at the Component definition.
Pattern This defines the file types you want to pull from the Repository, such as *.exe, *.dll, *.war.
Pattern Encrypted Select the box to indicate the Pattern should be hidden in the database.
Pattern Override Select the box if the Pattern can be replaced at the Component definition.
Port The port used to connect to the HTTP Endpoint.
Port Encrypted Select the box to indicate the Port should be hidden in the database.
Port Override Select the box if the Port can be replaced at the Component definition.
Endpoint The hostname of the HTTP Endpoint.
Endpoint Encrypted Select the box to indicate the Endpoint should be hidden in the database.
Endpoint Override Select the box if the Endpoint can be replaced at the Component definition.
Version Value optional. DeployHub will generate a Version number for the files extracted if no Version is entered.
Version Encrypted Select the box to indicate the Version should be hidden in the database.
Version Override Select the box if the Version can be replaced at the Component definition.

File System Repository Details

Field Description
Filepath The fully qualified directory name to the files that will need to be deployed. These files must be on a file system that the DeployHub deployment engine has access to.
Filepath Encrypted Select the box to indicate the Filepath name should be hidden in the database.
Filepath Override Select the box if the Filepath can be replaced at the Component definition.
Pattern This defines the file types you want to pull from the Repository, such as *.exe, *.dll, *.war.
Pattern Encrypted Select the box to indicate the Pattern should be hidden in the database.
Pattern Override Select the box if the Pattern can be replaced at the Component definition.
Recursive Select the box in order to cause the Repository to return all of the files from directories below those designated by Filepath.
Recursive Override Select the box if the Recursive option can be replaced at the Component definition.
Version Allows for the auto generation of a version number based on a template that you define. Enter the template with variables, such as V${buildnumber} to create your unique version number upon deployment. This is most commonly used with DMScript.
Version Encrypted Select the box to indicate the Version should be hidden in the database.
Version Override Select the box if the Version can be replaced at the Component definition.

Git Repository Details

You can configure DeployHub to call out to a Git Repo to pull deployable artifacts (binaries, scripts, etc.) as part of your deployment. The process will check out your deployable artifacts based on commit, branch or tag specified. You will need to configure DeployHub with a file system DeployHub Repository that will pull the files need for the deployment. You will also need to create a “Git Checkout” Procedure and Action.

Step 1 - Create a DeployHub File System Repository

DeployHub can use Git as a binary repository for retrieving deployable objects as part of the deployment process. To do this you will first need to define Git as a connected Repository Object from within DeployHub. This connection will be used by as part of the deployment process using a Procedure and a Action. Once you have completed this step, you are ready to create a new Procedure that performs the check out from the Git repository.

Step 2 - Create your Git Checkout Procedure for your Action

Procedures are called by Actions to execute deployment logic. A pre-defined DeployHub _Procedure__is available from the Ortelius Git Repo. This where you will find the most current version of this Procedure. For more information on creating_Procedures see Functions and Procedures.

From the Ortelius Git Repo, pull the file named GitCheckout.re

Once downloaded, you will need to Import it into DeployHub from the Func/Procs List View. Navigate to the List View by selecting the Func/Procs menu option on the left hand side of the DeployHub main panel. From the Func/Procs List view select the Import option. The Import will bring you to your operating system “file open” dialog box for selecting the GitCheckout.re file. Next, select your Domain and upload the Procedure into the DeployHub. You are now ready to create your Action.

Step 3 - Create your Action for the GitHub Checkout Procedure

Once you have imported your GitCheckout.re Procedure, you can define your Action. Navigate to the Actions list view from the Actions menu option on the left hand side of the DeployHub main panel. Use the +Add option to create a new Action for you Procedure. Name the new Action GitCheckAction (no spaces). See Customize Your Actions for more information on creating Actions.

Now we are going to customize this Action. On the right hand side, you will see a list of Functions and Procedures you can choose from. Navigate to your Domain to find the GitCheckOut Procedure. Drag it onto the area under Start. A pop-up dialog box will open for you to complete the following parameters:

GitCheckout Parameters

Field Value Description
Title Not Required Name of the step in your deployment workflow. Use “Git Checkout.”
Summary Not Required Enter a summary of this step.
Git Repo $GIT_URL This Variable represents the Git Repo containing the deployable artifacts. The value will be defined at the Component Level.
Git Commit $GIT_COMMIT This Variable represents the Git the commit, tag or branch to checkout. The value will be defined at the Component Level.
To Dir $GIT_DIR This Variable represents the directory to checkout into. The value will be defined at the Component Level. Use “.” for the default directory when assigning this value at the Component level.

At this point the Action is ready to be used by anyone with access (based on Domain and Group options). Note: Because this Action is reusable, no Component variables are defined. This is performed at the Component level.

Step 4 - Assign the GitCheckoutAction to your Component to be deployed

For each Component you will need to define the variable values for $GIT_URL, $GIT_COMMIT and $GIT_DIR that the GitCheckoutAction will use at the_Component_ level. The values will be passed to the GitCheckoutAction at deploy time. See the Components chapter for more information.

Step 5 - Set Your Component Attributes_

The following variables must be added to the Attributes Section for all Components using the GitCheckoutAction Pre Action. The Attributes section can be found on the Component Dashboard. Use the +Add option in this section to add a row for the variable. You must use Save to commit the row to the table:

Variable Name Value Description
GIT_URL This Variable represents the Git Repo containing the deployable artifacts. The value will be defined at the Component Level.
GIT_COMMIT This Variable represents the Git the commit, tag or branch to checkout. The value will be defined at the Component Level.
GIT_DIR This Variable represents the directory to checkout into. The value will be defined at the Component Level. Use “.” for the default directory when assigning this value at the Component level.

OpenMake Meister Repository Details

If you automate your builds (compile/link) using OpenMake Meister, DeployHub pulls binaries from the Meister binary repository that your Component uses. Following is a list of the details for connecting a Meister repository to DeployHub:

Field Description
Buildnumber The identifier of the Build that resides in the Meister Repository.
Buildnumber Encrypted Select the box to indicate if the Build Number should be hidden in the database.
Buildnumber Override Select the box if the Build Number can be replaced at the Component definition.
Filepath The fully qualified directory name to the files in the OpenMake Meister repository that will need to be deployed.
Filepath Encrypted Select the box to indicate if the Filepath name should be hidden in the database.
Filepath Override Select the box if the Filepath can be replaced at the Component definition.
Pattern This defines the file types you want to pull from the Repository, such as *.exe, *.dll, *.war.
Pattern Encrypted Select the box to indicate if the Pattern should be hidden in the database.
Pattern Override Select the box if the Pattern can be replaced at the Component definition.
Recursive Select the box in order to cause the Repository to return all of the files from directories below those designated by Filepath.
Recursive Override Select the box if the Recursive option can be replaced at the Component definition.

SVN Repository Details

Files and binaries can be pulled from SVN when defining your Component. Below are the details needed to connect SVN as a Repository in DeployHub:

Field Description
Path The path to the files within the Subversion repository.
Path Encrypted Select the box to indicate the Path should be hidden in the database.
Path Override Select the box if the Path can be replaced at the Component definition.
Revision Refers to the Tag used within the Subversion repository that contains the versions of the necessary files.
Revision Encrypted Select the box to indicate the Revision should be hidden in the database.
Revision Override Select the box if the Revision can be replaced at the Component definition.
URL The Universal Resource Locator used to locate the Subversion repository.
URL Encrypted Select the box to indicate the URL should be hidden in the database.
URL Override Select the box if the URL can be replaced at the Component definition.

Repository Access Controls

The Access Section allows Users within designated Groups to update the Repository. To add a Group to one of the access lists, drag and drop the Group from the Available Groups list onto desired access list. All Users who belong to a Group that appear in one of the Access lists will be granted access to the Repository in the following ways:

Access Description
View If a User belongs to a UserGroup in the View Access list for the this Repository, the Repository will be visible.
Change This allows a User who belongs to any UserGroup in the list to change the attributes of the Repository.
Check-out Access Allows Users to check out files from the Repository. This is inherited from the Read Access of the parent Domain.
Check-in Access Allows Users to check in files to the Repository. This is inherited from the Write Access of the parent Domain.

Audit Trail

The Audit Trail displays audit entries for any changes that impact this Object.

  • Comment: Click on ‘Comment’ to add information. There is a field above the list labeled “Say something about this Object” that can have written comments placed into it, or files can be attached to the comment. Entering text into this field activates the Add Message button. Click to save the comment as a line in the list.

  • Add Files to Comments: Click on the paperclip icon to add a file to the message. Once done, click on the “Add Message” button. These attachments can later be retrieved by clicking on the paperclip icon which then displays the name of the file within a list. Choose the file to download it into the your default Download directory on your local computer.