Skip to main content

Fragments

Environment Variables

The fragments enable the storage of sentinels using Shamir's Secret Sharing scheme, which is why it is necessary to configure different servers and triggers. Ensure that these variables are set according to your deployment environment before starting the application.

VariableDescriptionDefault ValueExpected Values
FRAGMENTS_SHARESTotal number of fragments3number
FRAGMENTS_THRESHOLDNumber of fragments required to reconstruct the key (must be < to FRAGMENTS_SHARES )2number

If you make any changes, restart the API to apply the new configuration:

make update

Fragments.toml Configuration

The Fragments.toml file contains the necessary information to connect to the fragment databases. Make sure to configure the connections appropriately to ensure secure and reliable key management.

# Fragments.toml Configuration

# The fragments enable the storage of keys using Shamir's Secret Sharing scheme,
# which is why it is necessary to configure different servers and triggers.

nodes = [
{ host = "redis://fragment1.host:6379", password = "password1" },
{ host = "redis://fragment2.host:6379", password = "password2" },
{ host = "redis://fragment3.host:6379", password = "password3" }
]

Ensure each fragment section is properly configured to connect to your respective fragment databases.