Since TYPO3 v9.4 the extbase commandController is deprecated so I use the symfony console command replacement according to: https://docs.typo3.org/m/typo3/reference-coreapi/master/en-us/ApiOverview/CommandControllers/Index.html#cli-mode
Now my FooCommandController extends from Symfony\Component\Console\Command\Command
Since I need to work with TYPO3 data I need to get them via the extbase repositories. But my whole CommandController does not have the extbase context so loading the repo via extbase dependency injection is not possible.
Also creating them manually via makeInstance or objectManager->get() is not possible since there is no objectManager available in this context.
What is the correct/non-hacky way to get access to the extbase functionallity inside a symfony commandController?