Oh, that's a really specific question! You're definitely talking about the novel 'The Last Ship' by William Brinkley, right? The one about a US Navy destroyer surviving a global pandemic? It's not based on a single true story, no. But the chilling part is how it's built from a foundation of very real, very terrifying Cold War fears.
Brinkley served in the Navy himself during WWII, and that experience drips from every page. The technical details of shipboard life, the chain of command, the isolation—that's all drawn from truth. The premise, though, is a work of speculative fiction from the 1980s, playing on the era's dread of nuclear or biological annihilation. It's less 'this happened' and more 'this could have happened,' which in some ways makes it feel more immediate and haunting than a straight historical account.
I read it years ago and what stuck with me wasn't any claim to fact, but the visceral sense of procedure and duty in the face of total collapse. The true story isn't in the event, but in the portrayal of the military mindset.