My first idea was to use the Gitea instance of the Free Software Foundation Europe, but T&Cs strongly encourage only projects with direct relation to the FSFE activities, so personal projects don’t seem welcome.
The first-party Gitea platform seems to be in risk of becoming for-profit.
What’s wrong with gitlab?
It’s operated by a publicly traded company. That seems be an extreme case of “for-profit” that OP is trying to avoid.
It has an awful UI layout.
Try to publish code anonymously on gitlab with Tor. They won’t even let you login.
Why why I do it? I have some open source code there and I link to my repos from LinkedIn. My code is not secret. If it were I would self host my repos. I’m not saying gitlab is great for everything bitits is good for many things.
No protection from fire though. Just because you aren’t fussed about privacy, doesn’t mean others aren’t. Some folk like nudist beaches, others do not.