I've heard it is not recommended that you store flour. Wheat berries can be stored for the long term. For information, check sites related to long term storage of flour and grain to find what the hazards are.
I store rice, beans, pastas and split peas in soda bottles with O2 absorbers. Works great. I keep a small amount of flour (5lbs) stored, but I double bag it and then seal it in a plastic bin. Same thing with Maseca for tortilla. You can't go wrong with white rice and beans.