There are considerations on multiple levels here…
First of all the security exposure of your router, which is the gatekeeper of your network and exposed to the outside. Keep this small, avoid 'optional' services on this device, its hard- and software.
Then the hardware, in the past decade we've seen quite a lot of security improvements on the hardware side (memory randomization, NX, …), x86_64 and ARMv8 have gotten a lot of attention in this domain, ARMv7 only a little, mips basically none at all (its ISA development ceased in the late 90s). This does help hardening the software.
Finally the OS side, a typical router is mostly fixed function, it only filters- and forwards packets, but usually doesn't consume external (untrusted) input. The number of packages involved is rather limited and therefore also getting a lot of attention by OpenWrt developers, security updates will be released (with new image) in time for these. A server (http, file, mail, ...) needs to receive untrusted input, while at the same time having a rather large dependency stack, all of which may contain security issues - which need timely updates, daily. But OpenWrt isn't really catered to in-place upgrade, nor do the packages involved get as much attention as the more basic networking packages (even more so when it comes to timely attention). These may work in a more or less trusted home environment, but I really wouldn't expose these to the hostile internet.
If you want to host a public server, please run it on dedicated x86_64 or ARMv8 hardware, running an up-to-date general purpose distribution (arch, debian, fedora, gentoo, mageia/ mandriva, OpenSuSE, Ubuntu, …).