That's a start, but you still didn't list your hardware (CPU, GPU, PSU,...). From what little info you gave, it may be a heat problem. If you open the side cover on the case and play with the cover off, does it last longer before it shuts down?
I don't know about your keyboard, but that's a seperate issue.