Skip to content
This repository has been archived by the owner on Nov 20, 2021. It is now read-only.

Commit

Permalink
Wait for mapi infrastructure to be ready before validating CSRs
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisRx committed Oct 29, 2020
1 parent 704edb8 commit 6fd60f0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions controllers/csrapprover/validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,9 @@ func (r *CSRApproverReconciler) getMachine(ctx context.Context, nodeName string)
continue
}
if nodeName == m.Status.NodeRef.Name {
if !m.Status.InfrastructureReady {
return nil, errors.Errorf("infrastructure for machine %q is not yet ready", m.Name)
}
return &m, nil
}
}
Expand Down

0 comments on commit 6fd60f0

Please sign in to comment.