I have installed elasticsearch-5.4.0, its not take my envornoment variable in elasticsearch.yml file its throw "Exception in thread "main" java.lang.IllegalArgumentException: Could not resolve placeholder 'DOCKER_IP'"
i follow this document, same confiuration works in elasticsearch2.4.2, but not works 5.4.0
elasticsearch.yml:
network.host: ${DOCKER_IP}
http.port: 9200
action.destructive_requires_name: true
Full Error:
Exception in thread "main" java.lang.IllegalArgumentException: Could not resolve placeholder 'DOCKER_IP'
at org.elasticsearch.common.settings.PropertyPlaceholder.parseStringValue(PropertyPlaceholder.java:116)
at org.elasticsearch.common.settings.PropertyPlaceholder.replacePlaceholders(PropertyPlaceholder.java:69)
at org.elasticsearch.common.settings.Settings$Builder.replacePropertyPlaceholders(Settings.java:1096)
at org.elasticsearch.common.settings.Settings$Builder.replacePropertyPlaceholders(Settings.java:1056)
at org.elasticsearch.node.InternalSettingsPreparer.initializeSettings(InternalSettingsPreparer.java:136)
at org.elasticsearch.node.InternalSettingsPreparer.prepareEnvironment(InternalSettingsPreparer.java:115)
at org.elasticsearch.cli.EnvironmentAwareCommand.createEnv(EnvironmentAwareCommand.java:72)
at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:67)
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122)
at org.elasticsearch.cli.Command.main(Command.java:88)
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:91)
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84)
Suggest me How to fix this issue.