Problem:
Upgrading to Foreman 3.13 ran into an issue with the rake db:migrate scripts. Failed with an error of undefined method ‘organization’
Expected outcome:
For the db:migrate to complete
Foreman and Proxy versions:
Foreman and Proxy plugin versions:
3.13 and Katello 4.15
Distribution and version:
RHEL 9
Other relevant data:
Error from foreman-installer/katello.log
2025-01-14 20:23:33 [INFO ] [configure] /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/returns: StandardError: An error has occurred, this and all later migrations canceled:
2025-01-14 20:23:33 [INFO ] [configure] /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/returns:
2025-01-14 20:23:33 [INFO ] [configure] /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/returns: undefined method `organization' for #<Katello::Util::FakeActivationKey id: 8, name: "Red Hat
Enterprise Linux", description: nil, organization_id: 1, environment_id: 4, created_at: "2023-08-22 21:10:28.552603000 +0000", updated_at: "2023-08-22 21:27:43.731203000 +0000", user_id: 5, max_hosts: nil, content_view_id: nil, cp
_id: "8a48b82f8a1dcacf018a1f15ac5a0081", release_version: nil, unlimited_hosts: true, auto_attach: true, purpose_role: "Red Hat Enterprise Linux Server", purpose_usage: "Production">