Skip to content

Commit

Permalink
Merge pull request #56 from shopware/fix-migration-job
Browse files Browse the repository at this point in the history
fix: migration was checking for wrong container
  • Loading branch information
TrayserCassa authored Oct 16, 2024
2 parents a9f3648 + d2d1703 commit e6dda55
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion internal/controller/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ func (r *StoreReconciler) stateMigration(ctx context.Context, store *v1.Store) v
return v1.StateMigration
}

jobState, err := job.IsJobContainerDone(ctx, r.Client, migration, job.MigrateJobName(store))
jobState, err := job.IsJobContainerDone(ctx, r.Client, migration, job.CONTAINER_NAME_MIGRATION_JOB)
if err != nil {
con.Reason = err.Error()
con.Status = Error
Expand Down
4 changes: 2 additions & 2 deletions internal/job/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ func IsJobContainerDone(
}
}

err := fmt.Errorf("job not found in container")
log.FromContext(ctx).Error(err, "job not found in container")
err := fmt.Errorf("job not found in container: %s", containerName)
log.FromContext(ctx).Error(err, err.Error())
return JobState{}, err
}

Expand Down

0 comments on commit e6dda55

Please sign in to comment.