Right now, I have RasPBX running an a RaspberryPi. My phone system is pretty small with only 1 desk phone and 4 softphones. 6 lines including a dedicated voicemail line. For something bigger, I'd use AsteriskNOW on something with better specs. I virtualized it and had a pretty stable system running for a few months before I built up the RasPBX system. It only took me a few hours to make and receive the first test calls.
My outbound trunks are actually Google Voice numbers. I hope to register several sequential GV numbers (yeah, it matters to me) so I can have a DID for every user.
The only money I spent was on the RaspberryPi, but at $50 it wasn't that bad and I didn't even make the purchase specifically for the PBX. On top of that, my previous VoIP provider sent me a desk phone in error, refunded me for it, but never sent me a shipping label to return it so I ended up with a free phone.