Skip to content
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

Remove non-prod schedule variables #2

Merged
merged 9 commits into from
Aug 23, 2024
Merged

Conversation

adampie
Copy link
Member

@adampie adampie commented Aug 19, 2024

First MR switching multi-env schedule logic and variables into a single environment/variable.

Removed conditional logic for non-prod scheduling and related variables to streamline environment management. All schedules now use uniform variables regardless of environment, reducing complexity and potential errors.
@adampie adampie changed the title Remove non-prod variables in favour of calling the module once per environment Remove non-prod schedule variables Aug 19, 2024
Copy link
Member

@paulschwarzenberger paulschwarzenberger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that we need to take the references to local.env out of the module, however we also need to record these variations between prod and nonprod environments so that appropriate configurations and / or conditionals can be included in the code which calls the module.

I'd suggest starting an examples folder - which is in any case required to be compliant with the Terraform registry - and include two examples, one the default which I'd suggest should be nonprod and then another example passing in the variables for prod.

The default values should therefore be the nonprod ones, as that's more straightforward for people to start with.

Copy link
Contributor

github-actions bot commented Aug 20, 2024

Integration Test Results

20 tests  ±0   20 ✅ ±0   6s ⏱️ ±0s
 1 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit b72ffe3. ± Comparison against base commit cb6dcd3.

♻️ This comment has been updated with latest results.

Copy link
Contributor

github-actions bot commented Aug 20, 2024

Test Results

79 tests  ±0   79 ✅ ±0   0s ⏱️ ±0s
 1 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit b72ffe3. ± Comparison against base commit cb6dcd3.

♻️ This comment has been updated with latest results.

@adampie adampie self-assigned this Aug 20, 2024
Added HashiCorp providers (aws, archive, null, random) configurations to nonprod, prod, and organizations terraform files. Updated module configurations for domain_protect with scan and update schedules. Set IAM role for domain_protect in organizations example and changed default value of takeover variable to false.
examples/nonprod/main.tf Outdated Show resolved Hide resolved
examples/prod/README.md Outdated Show resolved Hide resolved
@nitrocode nitrocode force-pushed the remove-env-specific-code branch from 9cd584b to f9585e0 Compare August 23, 2024 14:26
Signed-off-by: nitrocode <[email protected]>
Copy link
Contributor

@nitrocode nitrocode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added some comments (Unsure why I have to submit a review to add comments now)

variables.tf Show resolved Hide resolved
variables.tf Show resolved Hide resolved
@nitrocode nitrocode merged commit f88d8d9 into main Aug 23, 2024
6 checks passed
@nitrocode nitrocode deleted the remove-env-specific-code branch August 23, 2024 21:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants