Commit Graph

20 Commits

Author SHA1 Message Date
Ciprian Hacman 2880e22bce Add flag for root volume encryption 2020-08-21 18:31:21 +03:00
Peter Rifel 69f2c71cc3
Add tag support to AWS launch templates
In addition to TagSpecifications which allow tagging of instances and volumes, launch templates support tags of their own.

This adds the usual tags to LTs, as seen in the kubernetes.tf additions. Cloudformation does not yet support it [0], so only "api" and "terraform" targets are updated.

[0] https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-launchtemplate-launchtemplatedata.html
2020-07-07 22:43:45 -05:00
Peter Rifel c5882446c8
Only store launchtemplate userdata in plaintext for terraform 0.12+ 2020-06-16 17:16:41 -05:00
Peter Rifel 964d402eb5
Store terraform launchtemplate userdata in plaintext rather than b64
This makes it easier to grok the userdata contents
2020-06-16 16:53:49 -05:00
Martin Tomes c66180bc58 Added support for instance interruption behavior 2020-04-29 14:53:17 +02:00
Peter Rifel 04a5ead08e Add cty field tags to Terraform structs 2020-04-05 21:18:02 -05:00
Kubernetes Prow Robot 759e24a490
Merge pull request #8802 from thejasbabu/feature/spot-block
Add support for Spot block in launch template
2020-04-01 10:15:27 -07:00
Thejas B dda8dc3f37 Add support for Spot block in launch template
- Launch configuration does not support the field SpotDurationInMinutes which is used to reserve the spot instances, but however Launch Template does
2020-03-31 20:07:01 +05:30
Peter Rifel ee86488d98 Don't set terraform's user_data if it is an empty string
Bastion hosts have no user_data by default.
This is not valid in terraform, based on the error messages reported here [0]

The Terraform provider code says user_data is optional for both LaunchConfigurations and LaunchTemplates [1] [2]

This change prevents the user_data property from being added to aws_launch_configuration and aws_launch_template resources unless the string is not empty.

[0] https://travis-ci.org/github/kubernetes/kops/jobs/662472020
[1] 04d24f80f3/aws/resource_aws_launch_configuration.go (L74-L76)
[2] 04d24f80f3/aws/resource_aws_launch_template.go (L510-L512)
2020-03-31 09:33:16 -05:00
Ciprian Hacman fb68aae41f
Apply suggestions from code review #1
Co-Authored-By: John Gardiner Myers <jgmyers@proofpoint.com>
2020-03-16 19:48:19 +02:00
Ciprian Hacman 59a6b065a0 Add root volume tags for CF and TF targets 2020-03-16 18:41:39 +02:00
mikesplain 9e55b8230a Update copyright notices
Also cleans some white spaces
2019-09-09 14:47:51 -04:00
Ryan Bonham 1c4775a46c We are not deleting the primary ENI for private networks on termination, which will run accounts our of ENIs. 2019-06-04 21:39:17 -05:00
Taehyun Kim ddf79be176 fix terraform spot_options key 2019-05-15 23:38:50 +09:00
Rodrigo Menezes d931c1ff60 defer the base64 encoding so that users get usable diffs 2019-04-07 14:31:45 -07:00
Rodrigo Menezes 9a44778eab When a network interface is provided, the security groups must be a part of it. 2019-04-07 14:17:13 -07:00
Rodrigo Menezes 63b7a9d4d9 Add launch template to use 2019-04-07 14:17:13 -07:00
Rohith 74af751dc6 - fixing up the conflicts post the additional volumes merge 2019-02-04 14:15:16 +00:00
Rohith ff25209381 - fixing up the terraform render to use the correct format for the device mappings (was using the launchconfiguration ones) 2019-02-04 12:00:04 +00:00
Rohith e2574f3938 - splitting out the code per target
- adding some unit testing for the terraform render
- adding the terraform render, updating the autoscaling and creating the launchtemplate
2019-02-04 12:00:04 +00:00