docker-splunk icon indicating copy to clipboard operation
docker-splunk copied to clipboard

Image with OpenJDK11

Open ryanfaircloth opened this issue 4 years ago • 3 comments
trafficstars

As a developer I would like to test certain integrations with Splunk DB Connect which requires JDK 11. I would benefit from a non default image with OpenJDK11 pre-installed for example by adding -openjdk to the end of the version tags with that installed

ryanfaircloth avatar Sep 24 '21 14:09 ryanfaircloth

@rfaircloth-splunk please pardon my ignorance. Are you unable to achieve the same using Environment Variable JAVA_VERSION=openjdk:11

Ref: https://splunk.github.io/splunk-ansible/ADVANCED.html#supported-environment-variables

dmanojbaba avatar Sep 30 '21 10:09 dmanojbaba

Yes however is potentially flaky and adds to startup time a constain correctly starting should not change itself really it should not be root to be able to do so

ryanfaircloth avatar Dec 02 '21 13:12 ryanfaircloth

I'm thinking about this but considering the wider question of what would be the best way to let the Ansible setup script run in CI to produce a pre-baked image which can have a quick startup time in production (in Kubernetes in our case).

So far the best (untested) workaround I came up with is:

  1. Run the Docker image with the right config files and env vars in CI with secrets from a KMS
  2. Watch the log output and keep checking for Ansible playbook complete, will begin streaming splunkd_stderr.log
  3. Stop the container
  4. Use docker commit to create an image
  5. Push the image to a private image repo

Is there any better way to manage this?

But also, I concur with Ryan that it would be good to have root disabled or maybe even have a mostly read-only instance in production (at least I would prefer not having any config possible to change runtime for any role other than a main Splunk UI instance).

daaain avatar May 24 '22 11:05 daaain