GitOps-enabled version control
From Digital.ai Release 10.2, you can use GitOps-enabled version control to store and track changes to folder entities in the form of YAML files (
Releasefile.yaml) within a Git repository.
You need to follow the steps to use the GitOps-enabled version control on a folder:
- Enable folder version control
- Configure a Git repository connection
- Configure folder version control
- Migrate the passwords on Configurations and Templates
You can enable or disable the folder version control feature on the Settings > Features pages. See Configure Feature settings for more details.
There are two locations where you can define a Git repository Connection :
- On a global level in Settings > Shared configuration
- On a folder level in Design > Folders, under the Configuration tab of the desired folder
To setup a git repository connection:
- In Digital.ai Release, go to one of the two specified locations
- Click the + icon next to Git: Repository
Enter the following details:
- In the Title field, enter a name for the configuration
- In the URL field, enter the address of the repository server as follows: http(s)://address:port/repository
- In the Authentication Method field, select the authentication method used for authenticating to the remote repository
In the Username and Password fields, enter the user ID and password/personal token
Note: To use the personal access token for Github and Bitbucket, select Basic from the drop-down list in the Authentication Method field.
To test the connection, click Test
Note: This will not test if the user has push permissions on the remote repository (required for Saving versions).
- To save the configuration, click Save
To setup folder versioning for a given folder:
- Select a folder and click Version control
- Click on the Configure button
- Select a Git repository from the dropdown, or click on New repository if you don’t have one
- Select a branch that you want to synchronize with. The branch must already exist on the remote repository
- Select a path in the repository where you want the
Releasefile.yamlto be stored. By default the path is the name of the folder
- Select a tag prefix that you want your commit tags to be prefixed with. By default it’s the folder name
- Select which entities you want exported to the local repository in the generated
- Click Save
Note: To configure folder version control, you need the Edit versions permission. See Version control permissions for details.
After the folder versioning is configured, Release will start cloning the repository locally, which might take a couple of minutes if the repository is very large.
The passwords in versioned entities will not be exported, instead the generated
Releasefile.yaml will have
!value somePassword placeholder tags. This is to avoid leaking passwords to a plaintext file on an external server.
The variables should be one of the following:
- Global password variables
- Folder password variables of a parent folder (not versioned)
- Folder password variables of the versioned folder, if you disable versioning for variables in folder version control configuration
- Folder password variables of the versioned folder, if they are External Password Variables with the Secrets Server configured outside the versioned folder
When you visit the Version control tab, there will be a list of commits under Version history.
Only the commits that are tagged in Git, where the tags begin with the same tag prefix as the configured tag prefix in folder versioning configuration, are listed.
The commits are ordered by the creation date.
The first element in the list (
Current) is the current state of your folder before it is saved.
The elements under Previous versions are the commits that exist in the Git repository.
In order to view the
Releasefile.yaml content of the commit, you must select it and press Preview code.
Note: To list versions and preview YAML, you need the View versions permission. See Version control permissions for details.
The commits listed in Version history are from the local repository on Release server. In order to synchronize with the latest changes on remote repository, you must click Fetch changes. When you hover over Fetch changes you will see the date the last time a fetch was done.
Note: To fetch changes, you need the View versions permission. See Version control permissions for details.
In order to export the current state of the folder into the remote repository:
- Go to Version control
- Under Version history click Current (pre-selected)
- Click Save as a new version
- Type in the Name field. This field will be used in the tag of the commit and appended to the configured tag prefix
- Type in the Description field. This field will be used in the commit message. If left empty, the Name field will be used in the commit message
Note: To save a new version, you need the Edit versions permission. See Version control permissions for details.
In order set the state of the folder to the one described in the
Releasefile.yaml of one of the previous versions:
- Go to Version control
- Under Version history click on a version you wish to apply
- Click Apply this version
- Click Apply in the modal
After the apply was successful, the version that was applied will have an Applied badge on it, until a new version gets saved.
Note: To apply a version, you need the Edit versions permission. See Version control permissions for details.
Note: The apply feature is experimental and the folder might not be set to exactly the same state as described in the
Releasefile.yaml of that commit.
Releasefile.yaml files that contain secret placeholders (
!value somePassword) will not be successfuly applied. You will get an error. You must use folder or global password variables on passwords for apply to work properly.