Decaying fish can glow due to bioluminescent bacteria, such as Photobacterium phosphoreum, that grow on the fish's surface as it decomposes. This is a form of bioluminescence where bacteria produce light through a chemical reaction, and this phenomenon has been observed in decaying fish for a long time. 
As a fish dies and begins to decay, bacteria that are already on or in the fish can start to multiply rapidly.
Some of these bacteria are bioluminescent, meaning they produce their own light. A common example is Photobacterium phosphoreum, which is often found on dead seafood.
The light is produced by a chemical reaction involving an enzyme called luciferase, which is similar to the one found in fireflies.
This glowing effect is not new; historical records from ancient Greece and Rome mention the light produced by decaying fish and other organic matter. 
This phenomenon only occurs when specific types of bioluminescent bacteria are present and thrive on the decaying fish.
The glow is a result of the bacteria, not the fish itself, and is a sign of spoilage.
While the glow itself is just from bacteria, it indicates that the fish is decomposing, so it should not be eaten.