Gov. Mario Cuomo and state legislators announced they had reached a deal that allow the state to move forward with a medical marijuana bill, Capital New York reports.

Five manufacturers and 20 dispensaries would be allowed statewide under the terms of the deal, according to the report. The drug would be used to treat specific medical conditions, including multiple sclerosis, A.L.S. and cancer, and the program would be monitored by the state health department.

A sunset provision would end the program after five years. The governor could also end the program immediately under a fail-safe provision, Capital New York reports.

Sources told the New York Daily that the bill would also include a prohibition against smoking marijuana.