03 subaru outback dead battery 1 headlght out security flashing

dead battery 1 headlight out security light gives two flashes constantly, gonna kill battery again. any ideas?

If the security light stays on while the engine is running then something is wrong with it. It does draw some power but not a lot. It would take some time to kill a good battery. Have the battery checked. You may just need a replacement. Have the charging system checked along with checking the current draw while the car is parked to see if there is an excessive current draw on the battery, You should not have more than a 30 milliamp draw on the battery.