And yes, they interview you, give you an offer, and then do the background investigation. The TS/SCI can take 1-2 years to complete. And unfortunately you can't start until it's complete.
If you go work for a contractor they still have to complete the background investigation but they can often get you an interim secret and start paying you, then put you in for TS.
The pay is better at the contractor but you don't get a pension after 20 years.