Skip to content

Commit

Permalink
add POD_NAME env for injected pods
Browse files Browse the repository at this point in the history
Signed-off-by: Denis Tingaikin <denis.tingajkin@xored.com>
  • Loading branch information
denis-tingaikin committed May 14, 2022
1 parent 6f9468d commit 5899fe9
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions internal/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,14 @@ func (c *Config) initializeEnvs() {
},
},
},
corev1.EnvVar{
Name: "POD_NAME",
ValueFrom: &corev1.EnvVarSource{
FieldRef: &corev1.ObjectFieldSelector{
FieldPath: "metadata.name",
},
},
},
)
}

Expand Down

0 comments on commit 5899fe9

Please sign in to comment.