There are four main points of storage: the container, conditions, location, and how to prevent bugs.
Storage Container
When storing your nuts and seeds use an airtight Ziplock bag or container. It is better to make small separate portions of the nuts and seeds to prevent the air from reaching all your nuts and seeds when you take out your desired portion of nuts or seeds. For example: store ¼ cup of nuts in one bag and ¼ cup in another so that when you need ¼ cup of nuts only that one bag is exposed to air instead of all your nuts.
Storage Conditions
You need to keep your nuts and seeds away from air and humidity and in an airtight container. When storing nuts for a short amount of time you can keep them in a cool dry place with low humidity. If storing for long term, keep them in the fridge or freezer. Nuts can keep in the fridge for up to 9 months or in the freezer for a year.
Fresh nuts with the longest storage time frame are shelled nuts. You can store them in the fridge or freezer.
Storage Location
Just like the other ingredients, keep your nuts off the floor and away from any detergent or chemicals.
Bug Prevention
If you want to prevent bugs than roasting/cooking your nuts, then storing them in a cool place or storing in the freezer prevents bugs from hatching.