Lifelong Safety Alignment for Language Models