It is easy to launch the outer gas of the star so that it escapes from the star ! the final stage of the sun's life will be the ejection of the outer helium and hydrogen layers . These outer layers are hot and glow. The glowing hot ejected gases called a planetary nebula.