SPLUNK_LICENSE_MASTER_URL uses the protocol & management port from the local Splunk instance
tmartin14 opened this issue · comments
When setting up a docker instance to use a license master, the SPLUNK_LICENSE_MASTER_URL setting only allows for the hostname or ip address of the server. The underlying code assumes the protocol and port to be used for the connection are the same as the local instance.
The current code resides in https://github.com/splunk/splunk-ansible/blob/develop/roles/splunk_common/tasks/set_as_license_slave.yml:
Potential fixes could be either providing separate variables or simply allow the SPLUNK_LICENSE_MASTER_URL to include ://:.
Sample invocation:
docker run -t --name=splunk_test -d -p 8000:8000 -p 8088:8088 \
-e "SPLUNK_START_ARGS=--accept-license" \
-e "SPLUNK_PASSWORD=<password>" \
-e "SPLUNK_LICENSE_MASTER_URL=xx.xx.xxxxxxxx.xx" \
-e "SPLUNK_ROLE=splunk_standalone" \
splunk/splunk:latest
Sorry it's taken a while to address this - we'll see if we can squeeze this into the next sprint cycle.
I think we can probably make some adaptability for protocol/scheme and port, ala something like:
-e SPLUNK_LICENSE_MASTER_URL=http://license-master:8080
This will be out in the >=8.0.5 image set