today I start to play around with ansible, amazon-ec2 and ebs. After the automation for the provisioning of a new ec2-instance with ubuntu works I try attach an additional volume to an instance by extend my command as follow:
- name: Launch the new EC2 Instance
ec2:
aws_access_key: "AAAAAAAAAAAAAAAABBBBBBBBBBBBBBBCCCCCCCCCCCCCC"
aws_secret_key: "DDDDDDDDDDDDDDDDEEEEEEEEEEEEEEFFFFFFFFFFFFFF"
group: "webserver"
instance_type: "t2.micro"
image: "ami: ami-0767046d1677be5a0"
wait: true
region: "eu-central-1"
keypair: "my_keypair"
volumes:
- delete_on_termination: yes
device_name: "/dev/sdd"
volume_size: 10
volume_type: "gp2"
count: "1"
and expect an new volume with the device /dev/sdd but I get in the instance the device /dev/xvdd
I can live with that but I would like to understand why? Because every documentation I see so far is that there should be a link from xvdd sdd but this link don't exists.
Maybe someone here can me explain why ansible (or aws?) ignored the device name is this depending on the kind of storage (or ami?)
best regards
Dan