Step One – check drainage and grading where the deck will be built and fix any problems. Avoid disturbing the soil where the footings will go because footings need to set in undisturbed soil to prevent settling.
Set the ledger against the house wall or other solid structure and attach with lag screws. This must be done against a flat surface. Instead, use shims to create a flat surface. When setting your ledger you need to consider your decking material height/thickness. If you desire your deck to be level with an adjacent floor, your deck should be directly below the door jam of that room when finished.
Flashing should be installed between any wood and the house (unless it is a stucco house, then no need for flashing). Mark the foundation with string line, then mark the footing and post locations. Cast concrete footings in the ground, then attach the concrete piers on top to hold the posts. (Check building codes for required depth for footings.) Piers can be cast in place or pre-made.