Can I attack with Ezreal dashing, then the opponent buffs their unit from 3 to 5 might with Discipline, and then play Discipline to go from 3 to 5 might to make Ezreal ability deal 5?

Yes, you can do this.

Because Ezreal's ability is a triggered ability that deals damage equal to his Might at the time of resolution, you can respond to his attack trigger by playing Discipline to increase his Might.

The Sequence

  1. Ezreal attacks: He moves to the battlefield and becomes the Attacker. His "When I attack" ability triggers.
  2. Chain starts: You place Ezreal's attack trigger on the chain.
  3. Opponent reacts: Your opponent plays Discipline on their unit. This goes on top of the chain.
  4. You react: You play your own Discipline targeting Ezreal. This goes on top of the chain.
  5. Resolution (LIFO - Last-In, First-Out):
    • Your Discipline resolves: Ezreal gets +2 Might (total 5).
    • Opponent's Discipline resolves: Their unit gets +2 Might.
    • Ezreal's attack trigger resolves: It checks Ezreal's current Might (which is 5) and deals 5 damage to the target.

According to RiftJudge FAQ #259, there is no mechanism that "locks in" the Might value when the trigger goes on the chain; the ability checks the unit's Might value only when the ability actually resolves.