Skip to content

Commit

Permalink
change creation of restBaseUrl
Browse files Browse the repository at this point in the history
  • Loading branch information
janheise committed Jul 12, 2023
1 parent dedfdd9 commit 440ddaf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public OpensearchConfiguration get() {
return new OpensearchConfiguration(
datanodeConfiguration.opensearchDistribution().directory(),
Path.of(opensearchConfigLocation),
localConfiguration.getHttpBindAddress().getHost().equals("0.0.0.0") ? Tools.getLocalCanonicalHostname() : localConfiguration.getHttpBindAddress().getHost(),
localConfiguration.getHttpBindAddress().getHost(),
localConfiguration.getOpensearchHttpPort(),
localConfiguration.getOpensearchTransportPort(),
localConfiguration.getRestApiUsername(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public Environment getEnv() {

private String getHostName() {
if (host != null && !host.isBlank()) {
return host;
return host.equals("0.0.0.0") ? Tools.getLocalCanonicalHostname() : host;
} else {
return Tools.getLocalCanonicalHostname();
}
Expand Down

0 comments on commit 440ddaf

Please sign in to comment.