Sometimes I get erection in mornings but I do not masturbate or have sexual thoughts, it seems like my private part gets erection automatically, would I require ghusl? I don't think anything comes out.
No it isn't required by default.
In this context ghusl is only required if you have intercourse or an ejaculation (intercourse, wet dream, masturbation etc.).
For further information refer to my answers on If I feel a drop of urine come out when I’m performing ghusl, do I need to restart?? and What should be done after sex according to Islam? and the included links.
Note that these kinds of erection might also occur to babies and old men and some people witness this more often than others. In the past people explained it as an effect of a full bladder.
But from observations in the somnology physicians now came to the conclusion taht this is a result of a high activity -inside the human body- during the REM-Phase (Rapid Eye Movement) in the morning hours which leads to a high frequency of both pulse and breathing. This again leads to a stronger blood supply in the penis and a higher oxygen saturation (the smallest vessel will be supplied with blood and oxygen) which both result in many erections while sleeping and what you witness is simply the last one.
Note that humans dream in each of the sleeping phases, so having nocturnal emissions or wet dreams can't be excluded at all.
But there's not necessarily a sexual background for this phenomenon at all and therefore neither ghusl nor wudu' would be required unless you find some liquid as in that case you might have had a wet dream in REM-Phase.