A definition that conveys the full range of the 'carry water' phrase's meaning, from pejorative to neutral, is this from OED:
to be the lackey of; to do the bidding of; to serve the interests of
OED notes that the use is US colloquial, and chiefly political. Observe also that the first element of the tricolon in the definition, "to be the lackey of", is distinctly pejorative; the second element is less so; the third element is neutral or complimentary, especially as used in a political context, given that politicians ostensibly do the job to serve others' interests.
Attestation in OED begins in the early 1960s with a splendid extended metaphor:
1963 R. McA. Brown tr. G. Casalis Portrait K. Barth ii. 68 The Russian authorities and the German communists..soon discovered that [Barth]..was not their man and that they had been deceived if they counted on him to carry water for the mill of eastern propaganda [Fr. pour apporter de l'eau au moulin de la propagande orientale].
The quote, as attestation, suggests the origin of the phrase may have been a similar French phrase. However, I find a much simpler derivation from this earlier phrase,
to carry water on both shoulders.
Like 'to carry water', 'to carry water on both shoulders' is and was used chiefly in political contexts. From its appearance only as early as 1862 in British newspapers, I surmise the phrase had a US origin. It was common in the US popular press during the 1950s and 1960s, as well as much earlier and later. The essential meaning is
to serve dual, not necessarily compatible, interests.
A example of linking use is this from The Cincinnati Enquirer, 06 Sep 1959 (paywalled):
On that labor reform bill, Sen. Jack Kennedy can wind up pretty wet, trying to carry water on his union shoulder.
The use not only antedates the early use of 'to carry water' in the translation from French, it implicates the other shoulder, but does not outright mention it.
Looking at early uses of the extended phrase, I easily traced it back an additional 136 years, to Montrose Gazette, and Susquehanna County Herald (Montrose, Pennsylvania), 19 Sep 1823 (paywalled):
The people in the northern secton of the state well know Charles Miner; they know that he is a bitter federalist, he will carry water on both shoulders to suit his own purposes; but when he is sounded to the heart, there is "rottenness in Denmark."
While the 1823 use is pejorative, as are many others, with suggestions of hypocrisy if not slavishness, the phrase is not always or only used in a derogatory sense. Sometimes those represented as carrying water for others on both shoulders, just as those today who simply carry water for others, are presented in a valiant, even heroic light.
However, none of the above should be construed as exculpation of the Republicans now 'carrying water' for, that is, coming to the aid of the White House. Their response after the fact must be seen as revelatory of the same "rottenness in Denmark", that is, self-interest and hypocrisy, ascribed to Miner in 1823.