The sun, mostly. Remember that on one half of Earth, it is day and on the other, it is night. The sun is heating up a portion of the ocean while other parts of it are cooling down because they're not receiving heat from it. As the Earth rotates, sun exposure in the ocean varies and so does its temperature.