What's the realistic life expectancy of modern hardware?
I ran a Ras. Pi system for monitoring my sprinklers and such but after about 9 months it has had some funkiness, I suspect power related and then the flash has had a couple little glitches. I couldn't see it lasting 5 years. I have an odroid-c1 that seems to be more robust in terms of power and such (it has a dedicated transformer, not some cheap USB that seems to "work") I do worry about the flash crapping out... Although if the policy is to burn a few flashes and just keep some spares, you should have quick recovery.
Maybe some good server grade hardware, in a data center, you can expect some decent life.
Most embedded system failures are due to power and I/O.
If you have robust power supplies from a reputable manufacturer (I like TDK/Lambda) with good filtering on the input (maybe external powerline filter modules), and you protect your external inputs and outputs, then the next thing to worry about is flash lifetime which should be measured in decades if you're not writing to it.
Problem with a Rasp Pi/Beaglebone is that it's running Linux and there are likely disk writes occurring, so your lifetime drops. If you can both limit disk writes and get long lifetime SSDs, I don't see why it shouldn't last at least 10 years.
The flash survival rate heavily depends on how the system is configured. If you move every writable directory (/tmp, /var/log, /var/run, etc) to a tmpfs filesystem and make the main filesystem readonly, it'll live much longer (and better survive hard reboots).
"What's the realistic life expectancy of modern hardware?"
Lower that it used to be. The design life for the Ford EEC-IV engine control system from the 1980s was 30 years. The program is mask-programmed onto the chip, and the parameter table is in a fuse-blowing type ROM. Many of those are still on the road.
With newer hardware, lifetimes are shorter. This is a big problem for long-lived military systems.[1] Electromigration becomes more of a problem as IC features get smaller.
There are embedded systems where 30-50 years of operation is needed. Pumping stations, HVAC, railroad signals, etc. have equipment which can run for decades with occasional maintenance. The NYC subway is still using century-old technology for signaling. It's bulky, but works well.
I read somewhere, actually I think it was an interview with Google's Saul Griffith, who said no smart phone was designed to run longer than 6 or 7 years in ideal circumstances. Realistically I imagine 5 years as unusually long regardless.