In this paper, we consider the heat-conducting compressible self-gravitating fluids in time-dependent domains, which typically describe the motion of viscous gaseous stars. The flow is governed by the 3D Navier–Stokes–Fourier–Poisson equations where the velocity is supposed to fulfill the full-slip boundary condition and the temperature on the boundary is given by a non-homogeneous Dirichlet condition. We establish the global-in-time weak solution to the system. Our approach is based on the penalization of the boundary behavior, viscosity, and the pressure in the weak formulation. Moreover, to accommodate the non-homogeneous boundary heat flux, the concept of ballistic energy is utilized in this work.