= Environment Trait

// Start of autogenerated code - DO NOT EDIT! (badges)
// End of autogenerated code - DO NOT EDIT! (badges)
// Start of autogenerated code - DO NOT EDIT! (description)
The environment trait is used internally to inject standard environment variables in the integration container,
such as `NAMESPACE`, `POD_NAME` and others.


This trait is available in the following profiles: **Kubernetes, Knative, OpenShift**.

NOTE: The environment trait is a *platform trait* and cannot be disabled by the user.

// End of autogenerated code - DO NOT EDIT! (description)
// Start of autogenerated code - DO NOT EDIT! (configuration)
== Configuration

Trait properties can be specified when running any integration with the CLI:
[source,console]
----
$ kamel run --trait environment.[key]=[value] --trait environment.[key2]=[value2] integration.yaml
----
The following configuration options are available:

[cols="2m,1m,5a"]
|===
|Property | Type | Description

| environment.enabled
| bool
| Deprecated: no longer in use.

| environment.container-meta
| bool
| Enables injection of `NAMESPACE` and `POD_NAME` environment variables (default `true`)

| environment.http-proxy
| bool
| Propagates the `HTTP_PROXY`, `HTTPS_PROXY` and `NO_PROXY` environment variables (default `true`)

| environment.vars
| []string
| A list of environment variables to be added to the integration container.
The syntax is either VAR=VALUE or VAR=[configmap\|secret]:name/key, where name represents the resource name,
and key represents the resource key to be mapped as and environment variable.
These take precedence over any previously defined environment variables.

|===

// End of autogenerated code - DO NOT EDIT! (configuration)
