My parents let me "cry it out" when I was a kid. I cried so much I got a mild hernia. Mild enough that it has never caused any problems. But it left a bump in my abdomen that I can still feel as a man in my late 30s.
If it's an epigastric hernia (which is most likely, considering it's caused you no issues and hasn't been operated on) then it most likely developed during the very early foetal stage. Epigastric hernias are largely a cosmetic nuisance as it's just fat from the abdominal wall (not intestinal tissue) that's poking through. However, sometimes that fat can get trapped and cause the area to become sore and red, but the body prunes the trapped fat off and reabsorbs it, unlike an abdominal hernia where trapped tissue can quickly become a life-threatening situation due to sepsis.
I also know someone who has a hernia from being sleep trained as a baby.