For chat, consider setting up your own Murmur server [1] and use Mumble to do voice and text chat. It is not has happy-clicky as Discord, but the sound quality is great and you can have thousands of people on a tiny VM. It is very easy to deploy. It looks like people have created ansible playbooks for this too. [2]
Mumble is pretty crummy for text chat from my experience. I still use it for voice on a fairly frequent basis, but having very ephemeral text logs (on client restart), and a lack of pinging users makes it a huge pain to use for text.
Yeah, I prefer IRC too. I ended up shutting down all my IRC servers. Most folks moved to Discord/Slack and it just wasn't worth the effort to maintain them for my use case.
I only suggest murmur / mumble because they are super east to set up.
A coworker suggested matrix, but I have been fine with murmur/mumble for my use cases. If a lot of people needed text chat, I would crank up the ol' IRC daemons and put TheLounge in front of it.
[1] - https://wiki.mumble.info/wiki/Main_Page
[2] - https://github.com/systemli/ansible-role-mumble
P.S. use their 1.3 RC version. It is very stable and much better than 1.2.