Override TAS manifests, config files, and variables
A Tanzu Application Service (TAS) service and environment are used together when you set up a pipeline to deploy your TAS app. You can configure your environment to override settings of the Harness TAS services that use the environment, thereby making the environment dictate TAS manifests, variables, and config file values.
For example, a TAS service uses a manifest.yaml
file that specifies specific routes, but an environment might need to change the routes because it is deploying the app in the manifest to a QA space.
Override TAS manifests
- Environment overrides
- Service overrides
To override the manifests of all services deployed to an environment, do the following:
-
In Environments, select an environment.
-
In the environment's Configuration tab > Environment Overrides, select + New Manifest Override under Manifests.
-
Specify a manifest type, and select Continue.
You can select TAS Manifest, TAS Vars, and TAS AutoScaler manifest types.
-
Follow the same steps as you would when adding a manifest, and then select Submit.
To override the manifests of specific services deployed to an environment, do the following:
-
In Environments, select an environment.
-
In the environment's Service Overrides tab, select New configuration overrides.
-
In Service, select a service you want to override when it is deployed to the selected environment.
-
In Override Type, select Manifest, and then select New Manifest Override.
-
Specify a manifest type, and select Continue.
You can select TAS Manifest, TAS Vars, and TAS AutoScaler manifest types.
-
Follow the same steps as you would when adding a manifest in a service, and then select Submit.
Override config files
- Environment overrides
- Service overrides
To override the config files of all services deployed to an environment, do the following:
- In Environments, select an environment.
- In the environment's Configuration tab > Environment Overrides, select + New Config File Override under Config Files.
- In Config File Selection, select the config file to override, and then select Submit.
To override the config files of specific services deployed to an environment, do the following:
-
In Environments, select an environment.
-
In the environment's Service Overrides tab, select New configuration overrides.
-
In Service, select a service you want to override when it is deployed to the selected environment.
-
In Override Type, select Config File, and then select New Config File Override.
-
In Config File Selection, select the config file to override, and then select Override.
-
Follow the steps to select the override file, and then select Submit.
Override variables
- Environment overrides
- Service overrides
To override the variables of all services deployed to an environment, do the following:
- In Environments, select an environment.
- In the environment's Configuration tab > Advanced (Optional), select + New Variable under Variables.
- In the New Variable dialog, in Type, select String, Secret, or Number, and enter a variable name.
- Enter an override value. It can be fixed value, runtime input, or expression.
- Select Save.
To override the variables of specific services deployed to an environment, do the following:
- In Environments, select an environment.
- In the environment's Service Overrides tab, select New configuration overrides.
- In Service, select a service you want to override when it is deployed to the selected environment.
- In Override Type, select Variable, and then select New Variable Override.
- In Add Variable, select the variable name, and enter an override value.
- Select Submit.
You can configure CLI environment variables override such as CF_STAGING_TIMEOUT and CF_STARTUP_TIMEOUT. Select the CLI Environment Variables in the Override Type dropdown and enter the Override Info such as Name, Type, and Value.
Certain CF CLI environment variables, such as CF_HOME, CF_PLUGIN_HOME, CF_USERNAME, CF_PASSWORD, CF_DOCKER_PASSWORD, CF_SKIP_SSL_VALIDATION, CF_ORG, and CF_SPACE are internally set by the system and will be ignored.
Currently, this feature is behind the feature flag CDS_CF_CLI_ENVIRONMENT_VARIABLE_SUPPORT
. Please contact Harness support to enable this feature.