In the first stanza, the speaker encourages the reader/listener to stay positive and confident especially when faced with chaos, doubt, and lies. However, in the final two lines, the speaker counters this by warning that it is important to avoid overconfidence as this might lead to self-righteousness. "And yet don't look too good, nor talk too wise." So, Kipling is saying two contradictory things: be confident but not overconfident. And yet they are not contradictory because both statements are sound pieces of advice.
Again, in Stanza 2, we have an apparent contradiction. That is to treat Triumph and Disaster the same. When you (reader) put your private thoughts into public action, they may become "twisted" to mean something else. With any such attempt to make your dreams become real, there is the potential for disaster and/or for triumph. They are "impostors" when enacted in the public domain because they will have been transformed in some way (from dream to material reality). Your dream in your private mind is pure. And even if it is successful in the public world, it is still not quite the same as that initial private dream.
Although there is the sense of privileging the pure, private dream over the real, public manifestation of that dream, the speaker does add (again giving both sides) that one should not simply be a dreamer and stop there. You need to keep trying. Triumph and Disaster are also "impostors" because they are temporary. You need to treat them the same, detach from them, move on to the next attempt. In Stanza 3, Kipling underscores this notion with:
If you can make one heap of all your winnings
And risk it on one turn of pitch-and-loss,
And lose, and start again at your beginnings
And never breathe a word about your loss;
The whole poem is an "if/then" statement with the extended "if" part dominating all but the final two lines. If you can treat Triumph and Disaster as impostors, as temporary impositions, then you can move on to other things.