You can petition for your spouse the day you become a US citizen provided the marriage is valid.  there is no need to wait any particular amount of time.  as long as you have the certificate of naturalization and all the other supporting documentation, you can petition for your spouse right away.