Here is mentioned: first, the way to wage the war; second, the necessity of a good conscience, at which some rejecting.
He says, therefore: that you war in them a good warfare. As if to say: you can wage a good war: first of all, having faith: this is the victory which overcomes the world, our faith (1 John 5:4); second, through a good conscience, because men quickly flee from things that are bothering them; hence, remorse of conscience is like a goad pricking a man with a bad conscience. That is why he is quick to flee from sin by obtaining a good conscience and true faith: I have conversed ...with all good conscience before God until this present day (Acts 23:1); our glory is this, the testimony of our conscience (2 Cor 1:12).
Then he shows why there is need of a good conscience, when he says, which some rejecting, have made shipwreck concerning the faith: first, he mentions the sin; second, the punishment; third, the fruit of punishment. He mentions the sin when he says, which, namely, a good conscience, some rejecting, have made shipwreck concerning the faith; for one who errs against the faith loses all he has: without faith it is impossible to please God (Heb 11:6); and he dies, because the just man shall live in his faith (Hab 2:4).
Source: Commentary on 1 Timothy