- 
                Notifications
    
You must be signed in to change notification settings  - Fork 68
 
First Release of MWAA Module #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this PR should be reviewed by @bryantbiggs or @vara-bonthu but heres just a few thoughts from me
| } | ||
| 
               | 
          ||
| variable "airflow_version" { | ||
| description = "(Optional) Airflow version of your environment, will be set by default to the latest version that MWAA supports." | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this a semantic version? can you add a validation here? https://dev.to/drewmullen/terraform-variable-validation-with-samples-1ank#semantic-version
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently allowed values are 2.2.2, 2.0.2 and 1.10.12. If you do not specify a version when you create an environment, the latest version is used. Do you still want to add a semantic version validation? what will happen if MWAA release a new version? do we will need to update the module to add the new version?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You could validate explicit versions... or you could just validate that the input looks like a server (which is probably what I would recommend)
You can do ~semver || null so users can omit
| 
               | 
          ||
| variable "airflow_configuration_options" { | ||
| description = "(Optional) The airflow_configuration_options parameter specifies airflow override options." | ||
| type = any | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you either change to object() or provide validations for the allowed keys in this variable? same for other any types where it makes sense
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for airflow_configuration_options I don't think I can convert to object since there are listed and custom options, https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-env-variables.html#configuring-env-variables-customizing
which means there is no way to map all possible options beforehand
and object type must contain all of the specified keys
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense to me, feel free to disregard
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@maiconrocha This looks great! Thanks for the PR. I am testing this one and send another PR if any changes are required.
@drewmullen Seen your comments which i will implement in my PR. I would like to add few more changes to this module so I am merging this one as a first commit. I will send another PR.
No description provided.