It was on its 5-year mission and was forbidden to participate in the war
In Star Trek: Discovery S02E01 ("Brother") we learn that the USS Enterprise, under command of Captain Christopher Pike, was on its 5-year mission when the war started (which covers Season 1 of DIS).
It was not supposed to participate unless absolutely necessary. Even then, they were far away from the war, so it would still take time to join the war effort.
PIKE: Missing the war while the Enterprise was on its five-year mission, that, uh took a toll on my crew, a toll on Spock. On me, too.
BURNHAM: Even if they had called you back, you were so far away, you wouldn't have made it in time. Starfleet ordered you to stay away for a reason. Enterprise was an instrument of last resort.