This document describes the environment variables supported by TestGen.
Sets logs to the debug level.
default: no
Invalidates the cache with the bootstrapped application causing the changes to the routing and plugins to take effect on every render.
Also, changes the logging level for the testgen.ui logger from INFO to DEBUG.
default: no
Enables generation of rotating file logs.
default: yes
File path under which to generate rotating file logs, when TESTGEN_LOG_TO_FILE is turned on.
default: /var/lib/testgen/log
Maximum log files to keep (one file per day), when TESTGEN_LOG_TO_FILE is turned on.
default: 90
Salt used to encrypt and decrypt user secrets. Only allows ascii characters.
A minimun length of 16 characters is recommended.
Secret passcode used in combination with TG_DECRYPT_SALT to encrypt and decrypt user secrets. Only allows ascii characters.
Username to log into the web application. Not used to connect to the database: set TG_METADATA_DB_USER for that.
Password to log into the web application. Not used to connect to the database: set TG_METADATA_DB_PASSWORD for that.
User to connect to the testgen application postgres database. Required outside standalone mode.
Password to connect to the testgen application postgres database. Required outside standalone mode.
User with admin privileges in the testgen application postgres database used to create the database and schema and to apply upgrades. Required if the user in TG_METADATA_DB_USER does not have the required privileges.
When this is a different user, setup and every upgrade grant TG_METADATA_DB_USER read and write access to the schema. To separate the two users after setup, or to change this user later, run testgen upgrade-system-version to grant that access. The admin user must own the TestGen schema.
default: os.environ["TG_METADATA_DB_USER"]
Password for the admin user to connect to the testgen application postgres database.
default: os.environ["TG_METADATA_DB_PASSWORD"]
Hostname where the testgen application postgres database is running in.
default: localhost
Port at which the testgen application postgres database is exposed by the host.
default: 5432
Name of the database in postgres on which to store testgen metadata.
default: datakitchen
Name of the schema inside the postgres database on which to store testgen metadata.
default: testgen
libpq sslmode for the connection to the testgen application postgres database: disable, allow, prefer, require, verify-ca or verify-full. When unset, libpq's own default applies, which negotiates TLS where the server offers it but does not verify the server certificate.
default: unset
Certificate authority used to verify the testgen application postgres database's server certificate. Either a path to a PEM bundle, or system for the operating system trust store, which carries the public authorities that managed postgres services chain to.
system pairs only with verify-full, so verify-ca needs a PEM path. A PEM path suits any mode, and require verifies the certificate chain against it in the same way as verify-ca.
default: system
Code used to uniquely identify the auto generated project.
default: DEFAULT
Name to assign to the auto generated project.
default: Demo
SQL flavor of the database the auto generated project will run tests against.
Supported flavors:
redshiftsnowflakemssqlpostgresql
default: postgresql
Name assigned to identify the connection to the project database.
default: default
Maximum number of concurrent queries executed when fetching data from the project database.
default: 4
Determine how many tests are grouped together in a single query. Increase for better performance or decrease to better isolate test failures. Accepted values are 500 to 14 000.
default: 5000
Name of the database the auto generated project will run test against.
default: demo_db
Name of the schema inside the project database the tests will be run against.
default: demo
User to be used by the auto generated project to connect to the database under testing.
default: os.environ["TG_METADATA_DB_USER"]
Password to be used by the auto generated project to connect to the database under testing.
default: os.environ["TG_METADATA_DB_PASSWORD"]
Hostname where the database under testing is running in.
default: os.environ["TG_METADATA_DB_HOST"]
Port at which the database under testing is exposed by the host.
default: os.environ["TG_METADATA_DB_PORT"]
For supported SQL flavors, set up the SQLAlchemy connection to trust the database server certificate.
default: no
Name assigned to the auto generated table group.
default: default
Key to be assgined to the auto generated test suite.
default: default-suite-1
Description for the auto generated test suite.
default: default_suite_desc
Comma separated list of specific table names to include when running profiling for the project database.
A SQL filter supported by the project database's LIKE operator for table names to include.
default: %%
A SQL filter supported by the project database's LIKE operator for table names to exclude.
default: tmp%%
A SQL filter supported by the project database's LIKE operator representing ID columns.
default: %%_id
A SQL filter supported by the project database's LIKE operator representing surrogate key columns.
default: %%_sk
API URL of your instance of Observability where to send events to for the project.
Authentication key with permissions to send events created in your instance of Observability.
Exporting events to your instance of Observabilty verifies SSL certificate.
default: yes
When exporting to your instance of Observabilty, the maximum number of events that will be sent to the events API on a single export.
default: 5000
When exporting to your instance of Observabilty, the type of event that will be sent to the events API.
default: dataset
When exporting to your instance of Observabilty, the key sent to the events API to identify the components.
default: default
Externally-reachable base URL for the TestGen web UI. Used in email notification links and PDF report links so recipients can click through to the correct address.
Must be set in production when TestGen is behind a reverse proxy or load balancer. If not set, defaults to http://localhost:<STREAMLIT_SERVER_PORT>.
Example: https://testgen.example.com
default: http://localhost:8501
Hides source-derived data values from the MCP surface, for deployments whose policies forbid exposing production values to an LLM. Accepts strict or off. An unrecognized value resolves to strict so that a typo cannot silently disable the protection. Changing it requires an MCP server restart.
default: off