File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -123,6 +123,14 @@ func (a *Actuator) Reconcile(cluster *clusterv1.Cluster) error {
123
123
kubeConfigSecret := & apiv1.Secret {
124
124
ObjectMeta : metav1.ObjectMeta {
125
125
Name : kubeConfigSecretName ,
126
+ OwnerReferences : []metav1.OwnerReference {
127
+ {
128
+ APIVersion : cluster .APIVersion ,
129
+ Kind : cluster .Kind ,
130
+ Name : cluster .Name ,
131
+ UID : cluster .UID ,
132
+ },
133
+ },
126
134
},
127
135
StringData : map [string ]string {
128
136
"value" : kubeConfig ,
Original file line number Diff line number Diff line change @@ -127,7 +127,7 @@ func (m *MachineScope) Close() {
127
127
return
128
128
}
129
129
130
- if m .Machine .Spec .ProviderID == nil || * m .Machine .Spec .ProviderID == "" {
130
+ if m .MachineStatus . InstanceID != nil && ( m . Machine .Spec .ProviderID == nil || * m .Machine .Spec .ProviderID == "" ) {
131
131
providerID := fmt .Sprintf ("aws:////%s" , * m .MachineStatus .InstanceID )
132
132
m .Machine .Spec .ProviderID = & providerID
133
133
}
You can’t perform that action at this time.
0 commit comments