Costello has an extensive history of convictions over an 11-year period between 2006 and 2017.
Despite not complying well with community-based sentences in the past, Judge Davidson said that on this occasion, Costello has shown interest in rehabilitation.
He has completed one counselling programme and a placement is available for him in another treatment facility early next year.
"Mr Costello, this was a fairly substantial amount of cannabis and clearly it had commercial motivations," Judge Davidson said.
"On the charge of possession of cannabis for supply, you are sentenced to 18 months' imprisonment."
Costello was also convicted for giving false details on a road, failing to remain stopped for an enforcement officer and driving while disqualified.