On Tue, Dec 30, 2014 at 12:18 AM, stewart mackenzie <[email protected]>
wrote:
Ie is there a way to make Nixops control Amazon's Elastic IP to
> automatically allocate and assign an IP address?
>
Yes. Here's a minimal nix expression that provisions and assigns an Elastic
IP:
let
region = "us-east-1";
accessKeyId = "testaccount";
instance = ip: {resources, ...}: {
deployment = {
targetEnv = "ec2";
ec2 = {
inherit region accessKeyId;
elasticIPv4 = resources.elasticIPs."${ip}";
};
in {
resources.elasticIPs.name-of-ip = { inherit region accessKeyId;
};
machine1 = instance "name-of-ip";
};
_______________________________________________
nix-dev mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-dev