It used to be 180 days but that 'rule' was scrapped and now you can apply at any time (unless you are a designated foreign national which you would be made aware of). Its sensible to apply right away though so you can acquire your PR at the earliest opportunity since this is a pre-requisite for amongst others applying for citizenship.