Skip to content

Commit

Permalink
Merge pull request #102 from greenmaid/Fix_filer_persistence_not_set
Browse files Browse the repository at this point in the history
Fix controler crash by checking if persistence is not nil
  • Loading branch information
chrislusf authored Feb 26, 2024
2 parents f205ad4 + bdc97b9 commit 9620476
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion controllers/controller_filer_statefulset.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func (r *SeaweedReconciler) createFilerStatefulSet(m *seaweedv1.Seaweed) *appsv1
},
}
var persistentVolumeClaims []corev1.PersistentVolumeClaim
if m.Spec.Filer.Persistence.Enabled {
if m.Spec.Filer.Persistence != nil && m.Spec.Filer.Persistence.Enabled {
claimName := m.Name + "-filer"
if m.Spec.Filer.Persistence.ExistingClaim != nil {
claimName = *m.Spec.Filer.Persistence.ExistingClaim
Expand Down

0 comments on commit 9620476

Please sign in to comment.