Here’s a the step by step on how to get joomla itself from 3.10 to 4. The joomla 4 to 5 is trivial, all extensions should work, rarely a 3rd party ext for 4 may not work on 5.
https://docs.joomla.org/Joomla_3.x_to_4.x_Step_by_Step_Migration
Then for the portal code, there’s a few removed/moved classes and methods that need to be replaced with the new ones, etc.
https://docs.joomla.org/J3.x:Developing_an_MVC_Component/Upgrading_to_Joomla4
There are some very good reasons for a separate web application for the portal.
- Many organizations (banks, government, financial, medical) have regulations and cannot expose their CRM to the internet for public login.
- Large customer base needs its own server with adequate resources to enable customers acceptable speed to access their own account views, payments, etc.
To make portal be more part of the CRM application, yet safely apart, the Admin page could add a one click install script that natively or with a docker container gets the joomla application and portal extension installed and configured on the system, isolated in its own user account or container.
This would keep the main CRM application, private customer info, and business info, out of reach from software security exploit attacks originating from internet users logged in on the portal.