Skip to content

Configuring Test Database

Endi S. Dewata edited this page Dec 6, 2021 · 9 revisions

Overview

By default the CI will perform the tests using a DS server installed from RPM packages. Sometimes it’s necessary to perform the tests using a different database configuration (e.g. installed from container). This can be done by creating a GitHub secret called BASE64_DATABASE to store the base64-encoded value of the test database configuration. To reset the test database configuration simply remove the secret.

Configuring Test Database

For example, to test using DS container:

{
    "type": "container"
}

Convert the value into a single line, escape the double quotes, then base64-encode the value:

$ echo "{\"type\": \"container\"}" | base64
eyJ0eXBlIjogImNvbnRhaW5lciJ9Cg==

Then create the secret:

  • Go to SettingsSecrets.

  • Click New repository secret.

  • Enter BASE64_DATABASE as the secret name.

  • Enter the base64-encoded value as the secret value.

  • Click Add secret

Resetting Test Repository

To reset the test repository, remove the secret:

  • Go to SettingsSecrets.

  • Click Remove next to BASE64_DATABASE.

  • Click Yes, remove this secret.

Clone this wiki locally