Construct main architecture of app