Commit Graph

64 Commits

Author SHA1 Message Date
SNA
686193ed4e feat: Add var.wait_for_cluster_timeout to allow configuring the wait for cluster timeout (#1420) 2021-06-01 23:10:31 +02:00
Thierno IB. BARRY
1d848b56bf fix: Remove duplicated security group rule for EKS private access endpoint (#1412)
NOTES: In this bug fix, we remove a duplicated security rule introduced during a merge conflict resolution in [#1274](https://github.com/terraform-aws-modules/terraform-aws-eks/pull/1274)
2021-05-28 21:11:02 +02:00
Thierno IB. BARRY
6d7d6f6f5a feat: Drop random pets from Managed Node Groups (#1372)
BREAKING CHANGES: We now decided to remove `random_pet` resources in Managed Node Groups (MNG). Those were used to recreate MNG if something change and also simulate the newly added argument `node_group_name_prefix`. But they were causing a lot of troubles. To upgrade the module without recreating your MNG, you will need to explicitly reuse their previous name and set them in your MNG `name` argument. Please see [upgrade docs](https://github.com/terraform-aws-modules/terraform-aws-eks/blob/master/docs/upgrades.md#upgrade-module-to-v1700-for-managed-node-groups) for more details.
2021-05-28 01:50:16 +02:00
Thierno IB. BARRY
1f22d24df6 fix: Add back depends_on for data.wait_for_cluster (#1389) 2021-05-25 11:06:04 +02:00
Thierno IB. BARRY
06e9078bf4 feat: Search for Windows or Linux AMIs only if they are needed (#1371) 2021-05-19 16:47:40 +02:00
Dov Salomon
f7d09a2901 feat: Remove dependency on deprecated hashicorp/template provider (#1297)
BREAKING CHANGES: We remove the dependency on the deprecated `hashicorp/template` provider and use the Terraform built in `templatefile` function. This will broke some workflows due to previously being able to pass in the raw contents of a template file for processing. The `templatefile` function requires a template file that exists before running a plan.
2021-05-17 10:25:38 +02:00
Daniel Piddock
7de18cd9cd fix: Revert removal of templates provider (#883)
Broke use case of passing in custom template content. Reverts most of the following PRs:
- #865
- #863 
- #854
2020-06-05 10:34:23 +02:00
Thierno IB. BARRY
9bfdba9fb8 chore: Move all locals in locals.tf (#865) 2020-05-06 14:00:20 +02:00
Daniel Piddock
b183b97253 improvement: Remove dependency on external template provider (#854)
* Remove template_file for generating kubeconfig

Push logic from terraform down to the template. Makes the formatting
slightly easier to follow

* Remove template_file for generating userdata

Updates to the eks_cluster now do not trigger recreation of launch
configurations

* Remove template_file for LT userdata

* Remove template dependency
2020-05-06 10:54:14 +02:00
Valeri GOLUBEV
2fd078e7c1 feat: Add support for EC2 principal in assume worker role policy for China (#827)
* Add support for EC2 principal in assume worker role policy for  China AWS

* Remove local partition  according to requested change

Co-authored-by: Valeri GOLUBEV <vgolubev@kyriba.com>
2020-04-11 14:11:22 +02:00
Albert Lloveras
4cc5753284 improvement: Use aws_partition to build IAM policy ARNs (#820)
* Use aws_partition to build IAM policy ARNs

* Update broken link to CONTRIBUTING.md in README.md
2020-03-30 16:09:41 +02:00
Yecheng Fu
8382f2c4e8 use the correct policy arns if the region is in CN (#765) 2020-03-09 16:02:53 +01:00
Tomislav Tomašić
124ea7c151 Add destroy time flag (#580)
* Add destroy-time flag

* Update changelog

Fix cluster count

* Fix cluster count

* Fix docs

* Fix outputs

* Fix unsupported attribute on cluster_certificate_authority_data output

Co-Authored-By: Daniel Piddock <33028589+dpiddockcmp@users.noreply.github.com>

* Remove unnecessary flatten from cluster_endpoint output

Co-Authored-By: Daniel Piddock <33028589+dpiddockcmp@users.noreply.github.com>

* Improve description of var.enabled

* Fix errors manifesting when used on an existing-cluster

* Update README.md

* Renamed destroy-time flag

* Revert removal of changelog addition entry

* Update flag name in readme

* Update flag variable name

* Update cluster referencing for consistency

* Update flag name to `create_eks`

* Fixed incorrect count-based reference to aws_eks_cluster.this (there's only one)

* Replaced all incorrect aws_eks_cluster.this[count.index] references (there will be just one, so using '[0]').

* Changelog update, explicitly mentioning flag

* Fixed interpolation deprecation warning

* Fixed outputs to support conditional cluster

* Applied create_eks to aws_auth.tf

* Removed unused variable. Updated Changelog. Formatting.

* Fixed references to aws_eks_cluster.this[0] that would raise errors when setting create_eks to false whilst having launch templates or launch configurations configured.

* Readme and example updates.

* Revert "Readme and example updates."

This reverts commit 18a0746355e136010ad54858a1b518406f6a3638.

* Updated readme section of conditionally creation with provider example.

* Added conditions to node_groups.

* Fixed reversed map_roles check

* Update aws_auth.tf

Revert this due to https://github.com/terraform-aws-modules/terraform-aws-eks/pull/611
2019-12-09 10:06:10 +01:00
Joonsung Lee
215dc849e8 Fix broken terraform plan/apply on a cluster < 1.14 (Fix #582) (#600) 2019-11-20 13:19:06 +01:00
Hwanjin Jeong
a4117177f6 Fix typo (#595)
* fix typos

* remove unnecessary comment
2019-11-18 18:10:53 +01:00
Scott Stanton
4f552891ff Allow the userdata template to be replaced (#565)
* Allow the userdata template to be replaced

* Address fmt issue

* Rename 'customer_userdata' name to 'userdata_template_file'

* Add support for userdata_template_extra_args

* Add support for userdata_template_extra_args

* fix merge conflicts

* Fix merge problem that dropped the file load
Add `platform` to the template expansion context
Add `userdata_launch_template` to `launch_template_userdata`
2019-10-29 12:12:47 +01:00
Joonsung Lee
2d52e06786 Add Windows support (#555)
* Add Windows support

* Assign eks:kube-proxy-windows group to worker nodes

* Add Instructions for adding Windows Workers at FAQ.md

* Remove unnecessary variables from userdata_windows.tpl

* Update CHANGELOG.md
2019-10-28 14:16:45 +01:00
Miguel Ferreira
3f346d1610 Remove region from vars mapping for kubeconfig (#556)
The template file data source was injecting a region variable that is not defined in the template. Once removed the variable the aws region data source was not used anywhere else, so it is removed as well.
2019-10-24 18:13:06 +02:00
Bruno M. Custódio
c81e1d2fa7 Allow for specifying a custom AMI for the worker nodes. (#551)
Signed-off-by: Bruno Miguel Custódio <brunomcustodio@gmail.com>
2019-10-21 13:04:04 +02:00
Roman Voitenko
f79c790153 Gpu workers support (#515)
* added posibility to use Amazon EKS-Optimized AMI with GPU Support for workers

* updated CHANGELOG.md

* added missing var prefix

* updated Changelog to ver 6.x.x
2019-09-23 17:50:01 +02:00
Sergiu Plotnicu
461cf5482e Support for Mixed Instances ASG in worker_groups_launch_template variable (#468)
* Create ASG tags via for - utility from terraform 12

* Updated support for mixed ASG in worker_groups_launch_template variable

* Updated launch_template example to include spot and mixed ASG with worker_groups_launch_template variable

* Removed old config

* Removed workers_launch_template_mixed.tf file, added support for mixed/spot in workers_launch_template variable

* Updated examples/spot_instances/main.tf with Mixed Spot and ondemand instances

* Removed launch_template_mixed from relevant files

* Updated README.md file

* Removed workers_launch_template.tf.bkp

* Fixed case with null on_demand_allocation_strategy and Spot allocation

* Fixed workers_launch_template.tf, covered spot instances via Launch Template
2019-09-13 16:50:59 +02:00
Karoline Pauls
630a0cc3fb Fix fmt for v0.12.6 (#460) 2019-08-06 17:26:05 +02:00
刘相轩
da2c78b8ba Upgrade to terraform 0.12 (#394)
* run terraform upgrade tool

* fix post upgrade TODOs

* use strict typing for variables

* upgrade examples, point them at VPC module tf 0.12 PR

* remove unnecessary `coalesce()` calls

coalesce(lookup(map, key, ""), default) -> lookup(map, key, default)

* Fix autoscaling_enabled broken (#1)

* always set a value for tags, fix coalescelist calls

* always set a value for these tags

* fix tag value

* fix tag value

* default element available

* added default value

* added a general default

without this default - TF is throwing an error when running a destroy

* Fix CI

* Change vpc module back to `terraform-aws-modules/vpc/aws` in example

* Update CHANGELOG.md

* Change type of variable `cluster_log_retention_in_days` to number

* Remove `xx_count` variables

* Actual lists instead of strings with commas

* Remove `xx_count` variable from docs

* Replace element with list indexing

* Change variable `worker_group_tags` to a attribute of worker_group

* Fix workers_launch_template_mixed tags

* Change override_instance_type_x variables to list.

* Update CHANGELOG.md
2019-06-19 09:57:51 +02:00
Max Williams
d6fa9f48ff Better examples, PR template changes, general tidy up (#375)
* adding 3 examples

* removing old example

* updating PR template

* fix this typo

* update after renaming default example

* add missing launch_template_mixed stuff to aws_auth

* fix 2 examples with public subnets

* update changelog for new minor release
2019-05-08 15:11:05 +02:00
Max Williams
f0838165e2 Fix annoying typo: worker_group_xx vs worker_groups_xx (#374) 2019-05-07 18:22:39 +02:00
Max Williams
ae2f8e58db Adding new mixed type of worker group with instance overrides and mixed instances policy (#371)
* Adding new mixed type of worker group with instance overrides and mixed instances policy

* moving all count and lifecycle rule parameters to top/bottom

* adding custom IAM parts

* updating doc with new options

* fixes for spot instances
2019-05-07 16:50:42 +02:00
Max Williams
2439c25771 Cleaning up and deduplicating launch template related code (#370)
* cleaning up launch template code

* update changelog

* Remove variable worker_group_launch_template_tags

* misc fixes

* fixing and simplifying example
2019-05-07 15:41:44 +02:00
Touch Ungboriboonpisal
959e5330e3 Support custom IAM roles for cluster and workers (#338)
* allow specifying custom worker IAM instance profiles

* allow specifying custom cluster IAM role

* add doc

* update changelog

* use data.aws_iam_instance_profile.name
2019-05-07 14:46:06 +02:00
Max Williams
8b2e1c2dd8 Replacing enable_docker_bridge with a generic option called bootstrap_extra_args (#320)
* Replacing enable_docker_bridge with a generic option called bootstrap_extra_args

* making breaking change more obvious
2019-03-26 17:20:39 +01:00
michaelmccord
80085f50ab Add enable_docker_bridge (#302) 2019-03-13 17:30:41 +01:00
Max Williams
95986471f0 Adding optional name filter variable to be able to pin worker AMI to a release 2019-03-05 14:57:22 +01:00
leonsodhi-lf
dfd5a8f808 Use launch template defaults for launch template userdata (#255)
* User launch template defaults for launch template userdata

* Updated changelog
2019-01-30 11:42:31 +01:00
skang0601
f3ab7c67da Allows worker groups to be created using AWS Launch Templates (#222) 2019-01-10 16:19:19 +01:00
Max Williams
e6671e45ae Changing AMI data resource to filter for k8s version of cluster (#215)
* Changing AMI data resource to only use k8s version of cluster

* Reverting this method as it doesn't work
2018-12-17 09:43:53 +01:00
Nic Grayson
e1e265bf21 allow user to overwrite the kubeconfig default args (#129)
* allow user to overwrite the kubeconfig default args

* quote args to auth command
2018-11-01 17:14:07 +01:00
Max Williams
fdd44c8f38 Cosmetic fixes (#131)
* changing syntax when referring to map keys without lookup function

* Replacing map function with actual maps for easier reading

* replacing map function in example

* replacing map function in workers.tf and readme/main

* update changelog
2018-09-25 12:30:56 +02:00
Touch Ungboriboonpisal
21f43b8341 Add support for the new amazon-eks-node-* AMI (#100)
* add support for the new amazon-eks-node-* AMI

* add CHANGELOG

* remove kubelet_node_labels
2018-09-04 12:19:02 +02:00
Daniel Piddock
23647950ad Easier overriding of workers_group_defaults (#107) 2018-08-30 11:21:46 +02:00
Daniel Piddock
13e1adc419 Remove unnecessary http callout and security rule
EKS masters are publicly accessible. You cannot restrict access nor
need to explicitly grant access.
https://github.com/terraform-aws-modules/terraform-aws-eks/pull/69#issuecomment-406123233
2018-08-03 21:52:16 +02:00
Andrew Lavery
5b1cf24931 add var 'worker_group_count' to replace 'length()' calls 2018-07-19 10:38:15 -07:00
Max Williams
58c4a0e30f initial commit 2018-07-11 10:21:53 +02:00
Max Williams
11cd282ec1 reverting some changes after feedback 2018-07-10 10:21:28 +02:00
Max Williams
f881745f00 formatting and minor cosmetic fixes 2018-07-09 12:19:16 +02:00
Brandon J. O'Connor
f385415c88 Merge pull request #52 from max-rocket-internet/kubeconfig-fixes
Making kubeconfig file path and generated config unique
2018-07-09 02:46:10 -07:00
Max Williams
7e4e93eeec Removing region from kubectl config and adding override variable 2018-07-09 10:40:51 +02:00
Bryan Shelton
9876ddbe71 Add a worker_groups option to define kubelet --node-labels 2018-07-07 17:26:03 -07:00
Max Williams
0ffa4932f6 clean up unused variables 2018-07-06 16:39:00 +02:00
Steve Davids
34cf66b47d Fixed terraform formatting 2018-06-29 20:49:40 -04:00
Steve Davids
efecd2ed87 Allowing a more configurable kubeconfig 2018-06-29 18:39:22 -04:00
jimbecker
81755336e8 added support for specifying user data for the worker launch config that runs before anything else 2018-06-27 11:51:34 -04:00