The final week, handled remotely
Schedule the signing a few days ahead of closing, end any utilities in your name on the closing date, and settle with Rudy where keys and remotes go for the buyer. Escrow will walk you through what happens to the tenant's deposit and the lease, and the closing statement is worth keeping.
The home-sale exclusion, worth as much as $250,000 of gain or $500,000 on a joint return, counts the time you actually lived there: 2 years out of the 5 before the sale (IRS Publication 523). A long stretch as a rental can push the years you lived there outside that 5-year window. Service members on qualified official extended duty (orders over 90 days, at least 50 miles away) may be able to suspend the 5-year period for up to 10 years. Under FTB Form 593, escrow may withhold part of the sale price for state tax when no exemption applies. A tax professional can run your dates.
Selling is also the usual path to getting your VA entitlement back. When the sale has closed and the VA loan balance is gone, ask for restoration online or by mailing VA Form 26-1880. That request comes after closing as its own step, and your lender can tell you how long it usually runs.