It is not allowed, with or without a prescription.
From Carnivals' Website:
Drug Free Zones Carnival recognizes that some states in the U.S. have fully legalized the use of recreational and/or medical marijuana. However, cruise lines are required to follow U.S. federal law, which strictly prohibits possession and use of marijuana and other illegal, controlled substances.
Since all cruise terminals in the U.S. are federal facilities, the terminals and our ships are drug-free zones. Law enforcement and federal agents are present at all terminal facilities to conduct screening measures and random searches may be implemented. All bags may be subject to drug screening, including at foreign ports of call where authorities are often present enforcing local laws. Any guest found to be in possession of illegal drugs will be denied boarding and no refunds or compensation will be issued. Additionally, guests may be subject to other actions as determined by the authorities.