-
Notifications
You must be signed in to change notification settings - Fork 127
Add Terraform Outputs to ServiceContext to use them in agent policy test config #1272
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
bd2fad6 to
321503f
Compare
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
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.
Nice. It wasn't too complicated to add. Most of the work was in testing.
internal/testrunner/runners/system/servicedeployer/_static/terraform_deployer.yml
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform_test.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/_static/terraform_deployer_run.sh
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform_test.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform_env.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform_env.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform_test.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform_test.go
Outdated
Show resolved
Hide resolved
|
/test |
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
internal/testrunner/runners/system/servicedeployer/terraform.go
Outdated
Show resolved
Hide resolved
09793f3 to
038d54a
Compare
💚 Build Succeeded
History
cc @bhapas |
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.
LGTM
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.
LGTM 👍
What does this PR do
This PR enables the terraform service deployer to generate terraform outputs and use them in the system test config to add terraform related data on agent policy config.
Why is this important
This enables the integrations developers to test
aws-s3input to use the terraform generated values like SQSqueue_urlin the system test config to run an agent to poll notifications from the underlying S3 bucket against the SQS Queue.How to test this PR
A system test package
aws_logsbeen created undertest/packages/parallel.make installelastic-package stack up -d -vtest/packages/parallel/aws_logsAWS_ACCESS_KEY_IDandAWS_SECRET_ACCESS_KEYinto the env variableselastic-package install -velastic-package test -vScreenshots
The
queue_urlis generated by terraform and added into agent policy config using handlebars template in system test config.Test Outputs
{ "queue_url": { "sensitive": false, "type": "string", "value": "https://sqs.us-east-1.amazonaws.com/<ACCOUNT_ID>/elastic-package-aws-logs-queue-<TEST_RUN_ID>" }, "triangle_output": { "sensitive": false, "type": [ "object", { "description": "string", "s_one": "number", "s_three": "number", "s_two": "number" } ], "value": { "description": "this is a triangle", "s_one": 1, "s_three": 2.5, "s_two": 2.5 } } }To access the variables in agent config
Related Issues