nixops-aws icon indicating copy to clipboard operation
nixops-aws copied to clipboard

ebsOptimized seems to have no effect

Open jekor opened this issue 7 years ago • 2 comments

I'm seeing the same issue as https://github.com/NixOS/nixops/issues/488

If I deploy the same instance in the same region and availability zone via the AWS console, it's EBS Optimized. If I deploy via nixops, EBS Optimized is false. Instance is m4.large.

jekor avatar Jun 08 '17 13:06 jekor

A workaround is to stop the newly-launched instance and run:

aws ec2 modify-instance-attribute --instance-id i-xxxx --ebs-optimized

Note that this does not work for spot instances as they cannot be stopped.

jekor avatar Aug 17 '17 05:08 jekor

The problem seems to be here: https://github.com/NixOS/nixops/blob/55391626bb8e9abad4609e9f4b8a6cbb8a19bce8/nixops/backends/ec2.py#L884-L891

If I set prefer_ebs_optimized to True I get an EBS Optimized instance. Note that I do not have any EBS volumes defined but I want to have an EBS Optimized instance for the volumes I will attach manually.

jekor avatar Aug 18 '17 02:08 jekor