Graham Cooper has been ordered to carry out 200 hours of unpaid work for producing 34 cannabis plants.
The 39-year-old, of Harewood Walk, Denton, pleaded guilty to the charge after the plants were discovered back in January 2019.
Magistrates ordered him to pay £85 court costs and a victim surcharge of £85.
They ordered the cannabis plants, equipment and paraphernalia to be forfeited and destroyed.

Community support event to bring local services to Hyde Town Hall
TPE introduces baby on board badges to support pregnant customers
Angela Rayner joins police officers on 'Day of Action'
Ex-smoker John urges others to quit after health scare