Elon Musk has earned a reputation as a man not afraid to take big risks and tackle big challenges. But is the touch Musk has shown in building a manufacturing empire for the 21st century—from SpaceX rockets to Tesla Motors electric cars and batteries—ready to help put a shine back on a depressed U.S. manufacturing city? We'll soon find out. SolarCity, the nation's largest seller of residential solar-power systems—of which Musk is chairman—is building a giant plant in Buffalo, New York, to make rooftop solar panels at a long-shuttered Republic Steel plant. Henry Ford had River Rouge; Musk and SolarCity have a Buffalo solar panel manufacturing plant named Riverbend.

A rendering of the SolarCity factory in Buffalo, N.Y. SolarCity

As the factory rises, a promised 5,000 jobs are just beginning to materialize. But it's not just a bet on Buffalo. How far the solar panel plant can go will also determine how well the domestic solar manufacturing industry can reclaim share after much of it was unable to survive the first half of this decade in a market roiled by steep price cuts and a trade war against Chinese solar panel makers. SolarCity, like many of the rooftop solar installers, grew its business for years by using cost-effective panels, including those made in Asia. The Buffalo plant is set to open next year and will employ at least 1,900 people once operating at full capacity in 2017. "You have a brownfield that has had no meaningful activity for years and you put in 3,000 jobs, not counting [its impact on] the local dry cleaner and mini-mart owner," said Peter Cutler, director of communications and special projects at Empire State Development in Buffalo.

Read MoreThe cover-up involving a big loss of US jobs Roughly 1,400 people are expected to work for suppliers, and another 2,000 supplier jobs are estimated to be generated in the rest of New York, said Alain Kaloyeros, president of the State University of New York Polytechnic Institute, who led the New York side of negotiations for the SolarCity incentive package.

"For [local] manufacturing, this is a gain of more than 5 percent, and Buffalo still has an outsized concentration of jobs in manufacturing,'' said Adam Kamins, a regional economist at Moody's Analytics. "To boost that with a modern industry is significant. If Buffalo can become a leader, which it's positioned to do, an investment like this can pay off.''

Buffalo, New York Richard Cummins | Getty Images

About 400 construction workers are building the plant now, a total expected to approach 1,500 late this year as the interior gets built out, said Frank Ciminelli, senior executive vice president of construction firm LPCiminelli, which is building it. "Something a tenth of this size would be noteworthy," Ciminelli said. "For a city whose psyche has been battered for as long as I've been alive, the site of multiple cranes on the skyline changes people's perspective. Even before it's been realized, it has changed the psyche of the city.'' The plant will make enough panels each year to produce a gigawatt of electricity, or a little more than 1 percent of the nation's power. That's slightly more than all the panels SolarCity buys now from outside manufacturers, but if the company maintains its historical 80 percent annual growth rate, the demand will be there by the time the plant hits full capacity, said SolarCity CEO Lyndon Rive, who is also Musk's cousin.

Read MoreRobot war is coming to US—on the manufacturing floor "My goal would be to do five gigawatts after this one," said Rive, a goal New York officials say he and Musk share. Rive said the expansion would have to be at a bigger site than the Republic plant, but likely in the same area. "It sets up the state to be the solar capital of the country. It creates manufacturing, it creates a market, and it creates infrastructure for how clean-energy companies will work together.'' The panels will be based on new technology innovated by Silevo, a company SolarCity bought last June for $200 million, plus incentives tied to how many panels the company can produce. The panels work by adding more layers of semiconductor material to existing technology and should be about 30 percent more efficient than most of what the company uses now, SolarCity spokeswoman Kady Cooper said.

New York's Rust Belt revival

As aging Rust Belt cities go, Buffalo has been in better shape than many. Despite losing 10,000 manufacturing jobs in the last decade, the metro unemployment rate is 5.5 percent, exactly the national average. (By contrast, Detroit is at 6.2 percent.) But the city is part of a relatively depressed upstate belt New York Gov. Andrew Cuomo wanted to help out when he came to office in 2011. By 2012 the governor announced the so-called Buffalo Billion plan to pour $1 billion into economic development plans that now include an IBM 500-worker software research facility and offices for biotech contract researcher Albany Molecular Research.

It sets up the state to be the solar capital of the country. It creates manufacturing, it creates a market, and it creates infrastructure for how clean-energy companies will work together. Lyndon Rive SolarCity CEO

SolarCity's plant is part of a construction push in the Nickel City unlike any in memory, as money from the state and from natural-gas fracking baron and Buffalo Bills and Sabres owner Terry Pegula drives new and coming developments, including a children's hospital and a medical school complex. Silevo became the linchpin of the plan after New York officials spoke with more than 50 companies, said Kaloyeros, a nanotechnology expert who has run New York's push to attract semiconductor-related businesses to the Albany area. Silevo, it turned out, was for sale: The winning bidder was SolarCity, who turned what had been contemplated as a plant making enough panels to generate 30 megawatts of power per year into something much larger.

In return for its large investment, New York wanted guarantees—and protection—built into the incentive deal. Instead of giving SolarCity cash, New York is paying for the $350 million factory and an estimated $400 million of equipment. The state is keeping ownership of both plant and machinery to discourage SolarCity from moving, even at the end of the 10-year deal. SolarCity is expected to invest $6 billion locally, including operating costs, over the term of the deal, Kaloyeros said. Cutler said the deal requires at least $5 billion in investment from SolarCity. Read MoreWhy 'Made in USA' labeling is so complicated

Subsidies received by Musk-affiliated companies were recentlynegatively highlighted in a Los Angeles Times piece. Musk fired back in an interview with CNBC that incentives are helpful, but not necessary, and that the incentives his firms receive pale in comparison to subsidies given to other industries, including the oil and gas industry. The deal also requires that SolarCity pay New York $42 million for every year that the target of 5,000 jobs—including local supplier jobs and solar installer jobs across the state—isn't met, Kaloyeros said. If it is met within the four-year deadline and maintained for a decade as required by the deal, the $750 million incentive package works out to roughly $150,000 per job, or $15,000 per year, according to David Doyle, a spokesman for Kaloyeros at SUNY Polytechnic. Since most of the positions are expected to pay from about $50,000 to $150,000 (Erie County's median family income is just over $50,000), New York state income taxes on workers' salaries alone are likely to recover less than half of that money over the initial term of the deal.

Doyle said SolarCity's package does not exclude the company from applicable state corporate income taxes. Personal and corporate income taxes will recover some of the cost of the incentives over the 10-year term of the initial deal.

"Isn't it worth it to revive Buffalo, to have the premier facility of its kind in the world, and to retain ownership [of the plant and equipment]?" Kaloyeros said. "I'd say yes."

The SolarCity ripple effect

The plant is demanding enough specialized workers that construction companies began alerting local unions a year ago, giving them time to coordinate training, Ciminelli said. The construction industry employs only about 15,000 people in metro Buffalo, so a job this size demands preparation, he said. "We'll empty the benches," Ciminelli said. "In certain specialty trades, we're already importing workers." In addition, local community colleges are reworking job-training programs to nurture the development of the hoped-for solar manufacturing cluster, Kaloyeros said.

Read MoreHow Washington is really hindering job growth

The state hopes it sets off a rush of other solar-industry companies setting up shop in upstate New York looking to supply Solar City. Whether New York made a good deal will depend on how successful SolarCity is at convincing suppliers, and whether the company expands its own plant beyond the 1-gigawatt production target, said Kamins, the economist at Moody's Analytics.

If we're going to spend $1 billion, Andrew Cuomo is not going to spend it for nothing. Alain Kaloyeros president of the State University of New York Polytechnic Institute