I really wish that, someday, I could click on a cool link on Hacker News for a service that's personal document storage and syncing and, near the bottom of the page, would read the text "host this on your own server using [these instructions]."
You should give https://sandstorm.io/ a close look. I would describe it as a personal server platform. You can host it yourself or use a cloud provider. You can install ported apps or write your own. I'm using the cloud beta right now, and it's really cool. They claim that porting apps to Sandstorm is pretty easy, and I think their live demo proves them right: there are some useful apps ported already (https://sandstorm.io/apps/).