At GitLab we hired more than 10 people that first contributed to the project voluntarily. Including our CI lead Kamil and VP of Engineering Stan Hu. Our last hire that joined this way was Clement Ho that was an MVP (most valuable volunteer) on August 22nd, 2016.
(BTW I love GitLab and you guys are doing!)
Number 2 is: "you are working less on things that are great for the community and more on things that are great for your company" => I hope that at GitLab everything we do is good for the community. There is a split between working on great things that end up in the community edition and great things that end up in the enterprise edition (proprietary). Part of the community is using the enterprise edition, so those things are good for the community but at a reduced level. But I hope they are always things everyone can get excited about.
Another great example of a company like this is Sentry[1], which is fully open source, although I'm not sure if they've hired anyone from the community so far.
https://journal.dedasys.com/2007/02/03/in-thrall-to-scarcity...
Bu I guess the number of such projects are relatively small.
I got hired by a company that uses a big project. Several years later I had the opportunity to move to a team that does upstream open source work, and did.
Why would you need to ask for permission to open source your side project? Is that always the case?
1) You work on an open source project and an altruistic company hires you to keep working on it. This is ideal, and I've only ever seen it once (Sendmail hired a couple of core contributors to keep making Sendmail awesome back in the 90s).
2) You work on an open source project, people see the work because they use the project, and then offer you a job to keep working on the project, but slowly over time you are working less on things that are great for the community and more on things that are great for your company. I've seen this a lot.
3) You get hired by a company that uses a big project, and they ask you to start making modifications that are useful for the company. It turns out what you did was useful for everyone so you contribute it back. Sometimes it turns out to be a huge win and so you keep working on it. I saw this with Cassandra and some of the folks at Netflix.
4) You create a cool project and your company lets you open source it. It becomes well known and then other companies want to hire you for either 1, 2 or 3. I saw this a couple times were people left Netflix to go to Facebook or Google to continue work on an OSS project.
If you work on Chromium or Firefox, you'll pretty much be limited to Google or the Mozilla foundation (with some exceptions). So if you want to do it to learn some great code but don't have a particular project that you love, I'd suggest one of the more infrastructure projects that are widely deployed if you want to increase potential job prospects.
In summary: There are lots of ways to get paid to write OSS, but you may not like them all.