This commit is contained in:
parent
3075a88459
commit
bc383cd5b4
@ -61,6 +61,7 @@ TEMPLATES = {
|
||||
"splunk": {
|
||||
"splunk": {
|
||||
"image": "cr.smcm.xyz/coder-images/splunk",
|
||||
"uf_image": "cr.smcm.xyz/coder-images/splunkuniversalforwarder",
|
||||
"splunk_versions": ["9.1", "9.2"],
|
||||
"coder_user": "splunk",
|
||||
"coder_user_home": "/opt/splunk/etc",
|
||||
|
||||
@ -134,4 +134,49 @@ resource "coder_app" "splunk-lm" {
|
||||
read_only = false
|
||||
}
|
||||
}
|
||||
container {
|
||||
name = "uf"
|
||||
image = "{{uf_image}}:${data.coder_parameter.splunk_version.value}"
|
||||
command = ["sudo", "-E", "-u", "ansible", "/sbin/entrypoint.sh", "start"]
|
||||
image_pull_policy = "{{ image_pull_policy }}"
|
||||
|
||||
security_context {
|
||||
run_as_user = "{{ coder_user_uid }}"
|
||||
}
|
||||
|
||||
env {
|
||||
name = "SPLUNK_DEPLOYMENT_SERVER"
|
||||
value = "lm"
|
||||
}
|
||||
env {
|
||||
name = "SPLUNK_SVC_PORT"
|
||||
value = "8091"
|
||||
}
|
||||
env {
|
||||
name = "SPLUNK_PASSWORD"
|
||||
value = "Temp1234!"
|
||||
}
|
||||
env {
|
||||
name = "SPLUNK_START_ARGS"
|
||||
value = "--accept-license"
|
||||
}
|
||||
|
||||
resources {
|
||||
requests = {
|
||||
"cpu" = "250m"
|
||||
"memory" = "512Mi"
|
||||
}
|
||||
limits = {
|
||||
"cpu" = data.coder_parameter.cpu.value
|
||||
"memory" = "${data.coder_parameter.memory.value}Gi"
|
||||
}
|
||||
}
|
||||
|
||||
volume_mount {
|
||||
mount_path = "/opt/splunkforwarder/etc"
|
||||
name = "home"
|
||||
sub_path = "uf"
|
||||
read_only = false
|
||||
}
|
||||
}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user