I read a horror novel about that very thing, about thirty years ago. Let me see if I can find the title...
Ah- here it is. The Night Boat. U-Boat full of voodoo-cursed undead cannibalistic Kreigsmarine submariners.
“The Night Boat”.
Boy if that doesn’t say John Carpenter directed film or what!
That would make a good movie.