Skip to content

Commit

Permalink
fix some lint warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
ainoya authored and micahhausler committed Apr 26, 2020
1 parent d3c23dd commit 7362bae
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions pkg/handler/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -206,11 +206,11 @@ func (m *Modifier) updatePodSpec(pod *corev1.Pod, roleName, audience string) []p
}

volume := corev1.Volume{
m.volName,
corev1.VolumeSource{
Name: m.volName,
VolumeSource: corev1.VolumeSource{
Projected: &corev1.ProjectedVolumeSource{
Sources: []corev1.VolumeProjection{
corev1.VolumeProjection{
{
ServiceAccountToken: &corev1.ServiceAccountTokenProjection{
Audience: audience,
ExpirationSeconds: &m.Expiration,
Expand All @@ -223,7 +223,7 @@ func (m *Modifier) updatePodSpec(pod *corev1.Pod, roleName, audience string) []p
}

patch := []patchOperation{
patchOperation{
{
Op: "add",
Path: "/spec/volumes/0",
Value: volume,
Expand All @@ -232,7 +232,7 @@ func (m *Modifier) updatePodSpec(pod *corev1.Pod, roleName, audience string) []p

if pod.Spec.Volumes == nil {
patch = []patchOperation{
patchOperation{
{
Op: "add",
Path: "/spec/volumes",
Value: []corev1.Volume{
Expand Down

0 comments on commit 7362bae

Please sign in to comment.