top of page

Variables

  • Writer: Trapenok Viktor
    Trapenok Viktor
  • May 10, 2024
  • 1 min read

Updated: May 20, 2024

Variables is poverfull mechanism for customization.List of variables and values for deployment you can see on the specifications tab.

ree

Additionaly in project configuration we can create more variables.

ree

If you use helm chart in your service - the variables tab will contain a lot of variables parsed from values.yaml file. You can edit this vars and get changes in resulting yaml.

ree

This variables specified for service and are not available in other services in the same project.

Let`s try to add new variable and save

ree

Then you can see your variable in deployment sync vars.

ree

Good.

Now you can use this var in your yaml

ree
ree

But that is not all.

Value sources for variables

You can select where take a value for this variable.

ree

You can select one of this options:

Values defined at a Project Level

The simplest - hardcoded value in this form

Deployment Specific Variables

The link to other existed variable (copy value from other variable)

Deployment Configuration

Most useful - Take the value from deployment configuration UI. You can have a different values in different deployments. Unified dynamically create UI for your service configuration.

For our test var TestVar will set type Deployment Configuration and check deployments configuration. You will see a new tab and input for your variable.

ree

Change this value and check the resulting yaml.

ree

Variable types

You can define variable type and Variable input type.

  • Variable type - like in programming languages with strong typization. can be a boolean, string, number, array, map. (Type any means that unifie will not change your variable type. It will use the exact value.)

  • UI Variable Input Type - Affect only for UI.

ree

Type conversion is important for kubernetes.  For example, such params as "replicas" or "containerP

 
 
 

Comentarios


bottom of page