Heat oven to 350°F. Lightly grease 8 or 9-inch square pan. Melt margarine in medium skillet over medium-high heat. Add onions; cook and stir until crisp-tender. Stir in green chiles. Spoon chile mixture evenly into greased pan. Sprinkle with cheeses.
In small bowl, beat eggs slightly. Beat in sour cream and red pepper flakes. Spoon egg mixture evenly over cheeses. Sprinkle with tomato.
Bake at 350°F. for 35 to 45 minutes or until knife inserted in center comes out clean.