Officials from Egypt, Ethiopia and Sudan say they have reached a preliminary agreement aimed at clearing the way for the filling and operation of a $5 billion dam project on the Nile River.

The foreign ministers and water resources officials of the three countries concluded three days of meetings in Washington on Wednesday with Treasury Secretary Steven Mnuchin and World Bank President David Malpass.

The project, called the Grand Ethiopian Renaissance Dam, is around 70% complete and promises to provide much-needed electricity for Ethiopia’s more than 100 million people. However, Egyptian officials are concerned that filing the reservoir behind the dam too quickly could significantly reduce the amount of Nile water available to Egypt.

The joint statement late Wednesday did not give details on how long it would take to fill the dam, saying only that it should occur in stages during the rainy season, which generally runs from July to August. Earlier this month Ethiopia’s minister for water and energy, Sileshi Bekele, said Ethiopia wanted a filling time of 12 years while Egypt wanted 21.

The discussions this week were aimed at developing the rules and guidelines that would mitigate drought conditions based on the natural flow of the Nile and water release rates from the dam’s reservoir.

The guidelines said that filing the reservoir could continue into September under certain conditions, with the goal of achieving the early generation of electricity while providing mitigation measures for Egypt and Sudan in case of severe droughts.

“The ministers agree that there is a shared responsibility of the three countries in managing drought and prolonged drought,” the officials said in their joint statement.

The statement said these preliminary decisions on the dam’s operation will not become final until the countries agree on all points in a final operating agreement.

The countries plan to meet again in Washington on Jan. 28-29 with the goal of reaching a final agreement on the dam’s filing and operation.

“The ministers recognize the significant regional benefits that can result from concluding an agreement … with respect to trans-boundary cooperation, regional development and economic integration,” the joint statement said.

In an address to the United Nations General Assembly last fall, Egyptian President Abdel-Fattah el-Sissi said he would never allow Ethiopia to impose a “de facto situation” by filing the dam without an agreement on its operation.

Pro-government media in Egypt have cast the issue as a national security threat that could warrant military action, leading Ethiopia’s Nobel Peace prize-winning Prime Minister Abiy Ahmed to warn last year that if there’s a need to go to war over the dam project his country could muster millions of people. Abiy added, however, that only negotiation can resolve the current deadlock.