Following the visit to Kyiv by NATO Secretary General Jens Stoltenberg earlier this month, President Petro Poroshenko said Ukraine would seek to meet the alliance’s membership criteria by 2020. On July 17, he stated that Ukraine would pursue a membership action plan.

After more than three years of war with Russia, the desire to join NATO is entirely understandable. Polls show public support for a membership course. However, Poroshenko is setting himself and Ukraine up for disappointment.

To be clear, Ukraine as a sovereign state has a right to choose its orientation and to join alliances. All member states of the Organization for Security and Cooperation in Europe—including Russia—accepted that in the 1975 Helsinki Final Act.

But NATO also has a say in who joins the alliance. It is difficult to see NATO saying yes to Ukraine in the foreseeable future.

NATO has dealt oddly with Ukraine’s membership aspirations in the past. President George W. Bush personally tried to persuade his counterparts to grant Ukraine a membership action plan at the 2008 NATO summit in Bucharest. He failed to win consensus, but the summit communique language stated that Ukraine (and Georgia) would be members of NATO. The alliance had never said anything like that before regarding prospective candidates. The language seemed to be a consolation prize for the American president rather than something with operational relevance for the NATO-Ukraine relationship.

Ukraine today is involved in an undeclared, low intensity conflict with Russia in the Donbas. That is not a conflict of Kyiv’s choosing, but one forced upon it by Moscow. The Kremlin has organized, led, funded, armed and otherwise supported—in some cases with regular units of the Russian army—violent separatism in Donetsk and Luhansk of a kind that Russia itself would never tolerate (witness two wars in 25 years in Chechnya).

Even if the Donbas conflict were settled, there would remain the issue of Crimea and its illegal seizure, occupation and annexation by Russia.

Until the simmering conflict in the Donbas and frozen conflict in Crimea are resolved, Ukraine has little prospect of membership. Bringing Ukraine in with the ongoing disputes would mean that NATO would face an Article 5 contingency against Russia on day one of Kyiv’s membership. As European Parliament Vice President Graff Lambsdorff said, “the West is not ready to defend Ukraine”—and that is particularly true against a nuclear-armed Russia.

NATO foreshadowed its unreadiness to take in states with territorial or border disputes in 1995 in its study on the how and why of enlargement. That study called on potential aspirants for membership to resolve those disputes before joining—precisely because the alliance did not want to import Article 5 cases into NATO ranks.

There is no reason to think this attitude will change. So what should Ukraine do?

First, the Ukrainian government needs to manage expectations, not fan them. Setting membership as a goal with a fixed near-term date sets a target that will not be met. That failure will negatively affect public attitudes toward the government and toward NATO.

Second, Kyiv should continue to deepen its cooperation with NATO and incorporate the reforms that it would undertake in a membership action plan in its annual action plans with the alliance. Moscow reacts viscerally to the idea of a membership action plan for Ukraine, but it has not reacted in a similar way in the past to action plans that include virtually everything that is in a membership action plan except for the title.

Third, the Ukrainian government should energetically pursue the agreed plan. The reforms would strengthen the military and bolster democratic institutions (NATO is an alliance of shared values as well as interests). Such reforms make sense for Kyiv irrespective of whether or when it might hope to join the alliance.

Having agreed on a plan, Ukraine needs to implement. Unfortunately, its track record over the past 20 years of taking steps it has committed to with the alliance is weak, one reason why Kyiv’s corridor reputation in the halls of NATO headquarters is not what it should be. While there is nothing wrong with ambition, completely fulfilling a less ambitious plan rather than again falling short will win Ukraine more points with NATO.

Fourth, instead of pressing NATO for an early membership signal, the Ukrainian government should urge that the alliance maintain its open door policy. Kyiv cannot get in now. It wants to ensure, however, that “not now” does not become “never.”

This approach would keep Ukraine moving on a Westward trajectory. It would help the country become a more modern and resilient European state, better capable of resisting Russian pressure. It would avoid unrealistic public expectations. And it would position Ukraine to make a convincing membership bid when the opportunity arises.

Steven Pifer, a former U.S. ambassador to Ukraine, is a senior fellow at the Brookings Institution and author of “The Eagle and the Trident: U.S.-Ukraine Relations in Turbulent Times.”