Sale of a house with solar, federal tax accounting

Let's say I purchase a house for 100000. I install solar for 10000 on it. I live in the house for 3  years immediately after the purchase, and sell the house for 200000. How is the solar system treated upon sale? Is it treated as part of the house like a water heater? So we add the cost of the solar system to the basis, and eventually substract the basis from the sale of the house, to get the long term capital gains, or there is another way to account for the solar system separately.