Skip to content

Commit efa4412

Browse files
committed
Option to not load JDK/maven
1 parent d9c9486 commit efa4412

File tree

4 files changed

+15
-0
lines changed

4 files changed

+15
-0
lines changed

multipass/main.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,13 +30,19 @@ variable "splunk_presetup" {
3030
nullable = false
3131
}
3232

33+
variable "splunk_petclinic" {
34+
description = "Enabled Java Development environment? (true/false)"
35+
type = bool
36+
}
37+
3338
data "template_file" "user_data" {
3439
template = "${file("../workshop/aws/ec2/templates/userdata.yaml")}"
3540
vars = {
3641
access_token = "${var.splunk_access_token}"
3742
rum_token = "${var.splunk_rum_token}"
3843
realm = "${var.splunk_realm}"
3944
presetup = "${var.splunk_presetup}"
45+
petclinic = "${var.splunk_petclinic}"
4046
}
4147
}
4248

workshop/aws/ec2/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ resource "aws_instance" "observability-instance" {
152152
rum_token = "${var.splunk_rum_token}"
153153
realm = "${var.splunk_realm}"
154154
presetup = "${var.splunk_presetup}"
155+
petclinic = "${var.splunk_petclinic}"
155156
} )
156157

157158
root_block_device {

workshop/aws/ec2/templates/userdata.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,10 @@ packages:
1515
- podman
1616
- python3-venv
1717
- jq
18+
%{ if petclinic == true ~}
1819
- maven
1920
- openjdk-17-jdk
21+
%{ endif ~}
2022
- python3-pip
2123
- zsh
2224

workshop/aws/ec2/variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ variable "splunk_presetup" {
88
description = "Presetup the instance? (true/false)"
99
type = bool
1010
}
11+
12+
variable "splunk_petclinic" {
13+
description = "Enabled Java Development environment? (true/false)"
14+
type = bool
15+
}
16+
1117
variable "aws_instance_count" {
1218
description = "Instance Count (Usually 1)"
1319
nullable = false

0 commit comments

Comments
 (0)