WEBVTT

00:07.827 --> 00:08.792
Hello.

00:08.792 --> 00:12.932
In this lecture we will see how to set
an environment variable in Kubernetes

00:13.531 --> 00:16.854
given a pod definition file, 
which uses the same image

00:16.854 --> 00:19.484
as the Docker command 
we ran in the last lecture.

00:20.083 --> 00:23.859
To set an environment variable, 
use the ENV property.

00:24.119 --> 00:25.672
ENV is an array,

00:25.672 --> 00:29.448
so every item under the ENV property
starts with a dash

00:29.448 --> 00:31.271
indicating an item in the array.

00:31.531 --> 00:34.331
Each item has a name and a value property.

00:34.630 --> 00:37.250
The name is the name
of the environment variable

00:37.250 --> 00:41.104
made available with the container
and the value is its value.

00:41.625 --> 00:45.885
What we just saw was a direct way
of specifying the environment variables

00:45.885 --> 00:48.619
using a plain key value pair format.

00:48.984 --> 00:52.828
However, there are other ways
of setting the environment variables

00:52.828 --> 00:55.692
such as using ConfigMaps and secrets.

00:56.134 --> 00:57.685
The difference in this case

00:57.685 --> 01:02.164
is that instead of specifying value,
we say value from

01:02.164 --> 01:06.096
and then a specification
of ConfigMap or secret.

01:06.487 --> 01:09.638
We will discuss about 
ConfigMaps and secret keys

01:09.638 --> 01:11.305
in the upcoming lectures.

01:11.799 --> 01:13.154
That's it for this lecture.

01:13.154 --> 01:14.954
I will see you in the next.

