Terraform 如何处理关于分区的 AWS Elastic Block Store (EBS) 挂载?

How does terraform handle mounting an AWS Elastic Block Store (EBS) with regards to partitioning?

用于安装 EBS 的示例 terraform 代码片段(仅用于上下文):

resource "aws_ebs_volume" "ebs-volume-1" {
  availability_zone = "eu-central-1a"
  size              = 20
  type              = "gp2"
  tags = {
    Name = "extra volume data"
  }
}

resource "aws_volume_attachment" "ebs-volume-1-attachment" {
  device_name = "/dev/xvdh"
  volume_id   = aws_ebs_volume.ebs-volume-1.id
  instance_id = aws_instance.example.id
}

我已经通读了有关安装 EBS 的属性的 terraform 文档 here;但是,我不清楚块设备是如何分区的(或者这里的分区是否相关。

什么是EBS的解释:here

"aws_ebs_volume" 资源将创建 EBS 卷,"aws_volume_attachment" 将其放在 EC2 实例上。

请记住,您也可以在 "aws_instance" 资源中执行此操作。