# io.k8s.api.core.v1.EnvVar

From **Kubernetes**.

EnvVar represents an environment variable present in a Container.

- Type: `object`

## Properties

### `name`

- Required: true
- Type: `string`

Name of the environment variable. May consist of any printable ASCII characters except '='.

### `value`

- Required: false
- Type: `string`

Variable references $(VAR_NAME) are expanded using the previously defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. "$$(VAR_NAME)" will produce the string literal "$(VAR_NAME)". Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to "".

### `valueFrom`

- Required: false
Source for the environment variable's value. Cannot be used if value is not empty.

## JSON Schema

```json
{"description":"EnvVar represents an environment variable present in a Container.","properties":{"name":{"default":"","description":"Name of the environment variable. May consist of any printable ASCII characters except '='.","type":"string"},"value":{"description":"Variable references $(VAR_NAME) are expanded using the previously defined environment variables in the container and any service environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. Double $$ are reduced to a single $, which allows for escaping the $(VAR_NAME) syntax: i.e. \"$$(VAR_NAME)\" will produce the string literal \"$(VAR_NAME)\". Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to \"\".","type":"string"},"valueFrom":{"allOf":[{"$ref":"#/components/schemas/io.k8s.api.core.v1.EnvVarSource"}],"description":"Source for the environment variable's value. Cannot be used if value is not empty."}},"required":["name"],"type":"object"}
```
