A light transistor based on photons and phonons