Adelanto, California, population 32,000, is a little city in the middle of the desert, the kind of place you pass by without even noticing on the drive from Los Angeles to Las Vegas.

Like many of the cities in sprawling San Bernardino county, it faces severe financial problems, teetering on the edge bankruptcy. For a time, there was even talk of dissolving Adelanto and absorbing it into its larger neighbor Victorville.

But then, along came Johnny "Bug" Woodard and his big idea: Save Adelanto by legalizing marijuana. Woodard, a self-described gun-toting Tea Party Republican, decided to run for city council on the promise of turning around the town's finances by allowing the mass cultivation of cannabis within city limits.

"I had already picked out some property in Arizona to move my family to Arizona, because I really didn't think I'd be elected," says Woodard. "I mentioned the 'M-word.' Mention the 'M-word': political suicide."

But something surprising happened: Woodard won his race, defeating an incumbent and entering the office with a mandate. Adelanto's voters had booted out most of the previous city council and the mayor after they had tried to patch the budget with a utility tax hike, a wildly unpopular move in a city with an unemployment rate above 10 percent. Woodard's outside-the-box proposal seemed to make sense for a desert town with lots of cheap land and giant warehouses that hold everything from windmill turbines to predator drones.

The victory at the polls was only the beginning of the political battle, though, as entrenched local interest groups (such as the local school district, the sheriff's department, and representatives from the three prisons that provide many of the jobs in Adelanto) all lined up against his proposal. City council meetings could stretch to midnight and beyond as Woodard's proposal underwent eight months of heated debate.

The other council members studied the issue and the new mayor visited Colorado to check out its legal pot situation. Then, slowly but surely, everyone came around and supported Woodard's plan. The ordinance passed with a 4-1 vote, positioning Adelanto as the first Southern California city to legalize marijuana cultivation on a mass scale. And already, investors are flocking to buy up the land, generating a large spike in real estate prices.

"For years and years our city was treated as a bad stepchild by all these other cities, and now we have an opportunity, if we do this right, to be the ones they look to. It's going to be a role reversal," says Woodard.

This story originally aired on March 29, 2016.

For a glimpse at what's going on in Adelanto, watch the video above. Scroll down for downloadable versions. And subscribe to Reason TV's YouTube channel for daily content like this.

Approximately 6 minutes. Produced by Zach Weissmueller. Camera by Alex Manning and Weissmueller. Music by Josh Woodward, The Rope River Blues Band, and Silent Partner.