I did my last two by shooting against a flat background (which I removed and replaced with a uniform background in Photoshop), taking several shots until I got it right. I used a 135mm lens which is a good portrait FL, and stopped to about f8 to get a good DOF. Once I had the photo looking right (
no adjustments in Photoshop other than exposure and contrast), I copied and pasted it over this template, reduced the opacity to 50%, and used free transform to adjust the size and positioning until it matched (this guide has been adjusted to the proper actual size for 360dpi printing). Then, I returned it to full density and copied that layer to a new file which was sized correctly for trimming when printed at 360dpi. I printed on glossy using inkjet and that must have been acceptable, because the passport office used it on those two occasions without any issues.
Good shooting and safe travels