  We consider a one-dimensional Ising model each of whose $N$ spins is in
contact with two thermostats of distinct temperatures $T_1$ and $T_2$. Under
Glauber dynamics the stationary state happens to coincide with the equilibrium
state at an effective intermediate temperature $T(T_1,T_2)$. The system
nevertheless carries a nontrivial energy current between the thermostats. By
means of the fermionization technique, for a chain initially in equilibrium at
an arbitrary temperature $T_0$ we calculate the Fourier transform of the
probability $P({\cal Q};\tau)$ for the time-integrated energy current ${\cal
Q}$ during a finite time interval $\tau$. In the long time limit we determine
the corresponding generating function for the cumulants per site and unit of
time $\langle{\cal Q}^n\rangle_{\rm c}/(N\tau)$ and explicitly give those with
$n=1,2,3,4.$ We exhibit various phenomena in specific regimes: kinetic
mean-field effects when one thermostat flips any spin less often than the other
one, as well as dissipation towards a thermostat at zero temperature. Moreover,
when the system size $N$ goes to infinity while the effective temperature $T$
vanishes, the cumulants of ${\cal Q}$ per unit of time grow linearly with $N$
and are equal to those of a random walk process. In two adequate scaling
regimes involving $T$ and $N$ we exhibit the dependence of the first correction
upon the ratio of the spin-spin correlation length $\xi(T)$ and the size $N$.
