/ infrastructure / ssh.tf
ssh.tf
1  resource "aws_key_pair" "main" {
2    key_name   = "${var.project_name}-ssh-key"
3    public_key = trimspace(file("${path.module}/${var.ssh_public_key}"))
4  
5    tags = {
6      Name = "${var.project_name}-ssh-key"
7    }
8  }