Code clean up

Cleaned up the server code and added it. Split into folders. Renamed
init to home, as it is on the server.