generated from cloudposse/terraform-example-module
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding initial draft of new module (#2)
* initial commit * remove configs * move to modules folder * move to modules folder * Move providers block to main.tf * mid clean up * Remove logic from workspace submodule * Clean up outputs and versions from workspaces module * chore: general clean-up * chore: working config and project workspaces * chore: fix file trigger for config workspace * chore: move config module to root * chore: README * chore: interim commit * Initial commit * Updating comments * Adding support for custom project folders * Updating some comments * Updating comment in modules/variables/main.tf Co-authored-by: Erik Osterman <erik@cloudposse.com> * Making a few recommended updates * Updating examples & fixing a few things * Adding new example configs & renaming fixtures * Update examples/complete/config/ue2-dev.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update examples/complete/config/ue2-dev.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Updating README * Renaming example configs * Update examples/complete/config/gbl-root.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Formatting updates * Adding references to docs * More README updates * More README updates * More README updates * Updating example environment name * Making auto_apply and filename_trigger configurable via YAML config at the project level * Update examples/complete/config/ue2-testing.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Updating README * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Update README.yaml Co-authored-by: Erik Osterman <erik@cloudposse.com> * Documentation updates! * Fixing config example indentation * Update README.yaml Co-authored-by: Andriy Knysh <aknysh@users.noreply.github.com> * Update README.yaml Co-authored-by: Andriy Knysh <aknysh@users.noreply.github.com> * Updating example variable descriptions & defaults * Updating descriptions & Terraform format * Adding missing descriptions to project variables * Update modules/project/variables.tf Co-authored-by: Andriy Knysh <aknysh@users.noreply.github.com> * Update modules/project/variables.tf Co-authored-by: Andriy Knysh <aknysh@users.noreply.github.com> * Adding type to workspace 'name' variable * Fixing types * Updating descriptions * Additional description updates * Update variables.tf Co-authored-by: Andriy Knysh <aknysh@users.noreply.github.com> * Updating documentation and Github workflows * Fixing format Co-authored-by: Hugo Samayoa <htplbc@gmail.com> Co-authored-by: John C. Bland II <johncblandii@gmail.com> Co-authored-by: Dan Meyers <danjbh@users.noreply.github.com> Co-authored-by: Erik Osterman <erik@cloudposse.com> Co-authored-by: Andriy Knysh <aknysh@users.noreply.github.com>
- Loading branch information
1 parent
7c90b02
commit c856676
Showing
33 changed files
with
873 additions
and
148 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,3 +17,4 @@ | |
# Crash log files | ||
crash.log | ||
test.log | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
projects: | ||
globals: | ||
stage: testing | ||
environment: gbl | ||
|
||
terraform: | ||
example1: | ||
workspace_enabled: true | ||
custom_project_folder: example1-custom | ||
vars: | ||
my_input_var: "Hello world! This is example1!" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
projects: | ||
globals: | ||
stage: testing | ||
environment: ue2 | ||
|
||
terraform: | ||
example2: | ||
workspace_enabled: true | ||
terraform_version: 0.13.4 | ||
auto_apply: true | ||
# Optional filename trigger to match (default is *.tf) | ||
filename_trigger: "*.*" | ||
triggers: | ||
- uw2-testing-example2 | ||
- gbl-root-example1 | ||
vars: | ||
my_input_var: "Hello world! This is example2. This project uses a different version of Terraform and contains custom triggers!" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
projects: | ||
globals: | ||
stage: testing | ||
environment: uw2 | ||
|
||
terraform: | ||
example2: | ||
workspace_enabled: true | ||
vars: | ||
my_input_var: "Hello world! This is example1. It's disabled!" | ||
example3: | ||
workspace_enabled: true | ||
triggers: | ||
- gbl-root-example1 | ||
vars: | ||
my_input_var: "Hello world! This is example2. This project contains a custom trigger!" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
region = "us-east-2" | ||
|
||
namespace = "eg" | ||
|
||
environment = "ue2" | ||
|
||
stage = "test" | ||
|
||
name = "example" | ||
|
||
branch = "master" | ||
|
||
identifier = "void" | ||
|
||
ingress_submodules = true | ||
|
||
oauth_token_id = "abc123" | ||
|
||
organization = "cpco-test-automation" | ||
|
||
tfe_hostname = "app.terraform.io" |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,20 @@ | ||
# Configure the Terraform Enterprise Provider | ||
provider "tfe" { | ||
hostname = var.tfe_hostname | ||
token = var.tfe_token | ||
version = ">= 0.21.0" | ||
} | ||
|
||
module "example" { | ||
source = "../.." | ||
source = "../../" | ||
|
||
example = var.example | ||
config_file_path = "config" | ||
organization = var.organization | ||
|
||
context = module.this.context | ||
vcs_repo = { | ||
branch = var.branch | ||
identifier = var.identifier | ||
ingress_submodules = var.ingress_submodules | ||
oauth_token_id = var.oauth_token_id | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,5 @@ | ||
output "id" { | ||
description = "ID of the created example" | ||
value = module.example.id | ||
} | ||
|
||
output "example" { | ||
description = "Output \"example\" from example module" | ||
value = module.example.example | ||
description = "Outputs for the example module" | ||
value = module.example | ||
} | ||
|
||
output "random" { | ||
description = "Output \"random\" from example module" | ||
value = module.example.random | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
variable "my_input_var" { | ||
type = string | ||
default = "" | ||
} | ||
|
||
output "dummy_output" { | ||
value = var.my_input_var | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
variable "my_input_var" { | ||
type = string | ||
default = "" | ||
} | ||
|
||
output "dummy_output" { | ||
value = var.my_input_var | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
variable "my_input_var" { | ||
type = string | ||
default = "" | ||
} | ||
|
||
output "dummy_output" { | ||
value = var.my_input_var | ||
} |
Oops, something went wrong.