I am a bit concerned about how Matomo deals with security. All their PHP code is located in the public folder and they use nginx[1] rules to block access to scripts that are dangerous.
(With caveats: This is a toy pipeline. More work required to make it robust and probably not a great option for any site with reasonable traffic. But easy to get started and play.)
We found it to be nothing but trouble. Disappearing data, database servers bogging down under what should be trivial load because of inefficient SQL design, painful upgrade process, etc.