The sun is the symbol for life and light, the giver of life and the center of the
universe (at least for the old astrologers who never watched Star Trek...).
The sun is taken as a male planet, attached to Leo and taken as responsible for a human's basic temperament and vitality (the 'inner light').
Given its striking appearance at the skies and its utmost importance for life on earth it is not a miracle that the Sun always had a prominent place in mythology ever since.
In old Mesopotamia the Sun god (Utu or Shamash) was the eldest son of the Moon god and always second to him. Odd as it seems it becomes understandable when remembering that the Moon as the patron of the nomads and the source of the lunar calendar has been there first, while the Sun didn't rise to equal prominence until the advent of agriculture.
The name Utu translates as 'He who sheds a wide light'. He was seen as a warrior and the god of justice, the 'Lord of heaven and earth'. Unlike the gentle Moon god the Sun god could be cruel, burning the lands and bringing desastrous droughts - especially in the area where all the ancient cultures where located, the Middle East with its warm climate and its vast deserts. But he also throned in the skies with the brightest glory and was early associated with both Fire and power.
In old Egypt - a settled people - the Sun quickly rose to greater prominence than the Moon. Notable Sun gods have been Ra, Aton and Horus, and Khepera which was also seen as a Moon god by some people. Associated with a Scarabaeus Khepera was figured rolling the Sun (or the Moon) across the sky (Scarabaei are beetles often observed to roll little chunks of dung around).
The Greek equated the Sun god with Helios who drove the sacred Chariot of the Sun across the skies day after day. Well known is the story of his son Phaeton who one day drove his father's chariot but couldn't control the horses. Causing a lot of havoc by rushing the chariot to close to the earth (thus burning all of Africa) he was finally killed by Zeus (Jupiter). The story gave rise to the myth of the 'falling star' and also stressed the ambivalence of the Sun god's powers - glorious but also dangerous.
In Rome Helios turned to Sol and then Sol Invictus, the 'official state sun god' of the Roman Empire installed by emperor Marcus Aurelius Antoninus (Elagabalus) who ruled the Empire from 218 to 222. This was of course the ultimate expression of the Sun's attribute as a symbol of power and glory.