Yes, it's not an issue. As noted it may be faster and worth it to apply in Canada with urgent processing, but up to you. Note that you may not be able to board a flight to Canada until you do get the passport (or one of the very rare other ways to do so, intended only for emergencies and a big...