diff options
-rw-r--r-- | OpenSim/Framework/RegionInfo.cs | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index f764a34..d7a51ec 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs | |||
@@ -147,6 +147,7 @@ namespace OpenSim.Framework | |||
147 | public string RemotingAddress; | 147 | public string RemotingAddress; |
148 | public UUID ScopeID = UUID.Zero; | 148 | public UUID ScopeID = UUID.Zero; |
149 | private UUID m_maptileStaticUUID = UUID.Zero; | 149 | private UUID m_maptileStaticUUID = UUID.Zero; |
150 | private bool m_resolveAddress = false; | ||
150 | 151 | ||
151 | public uint WorldLocX = 0; | 152 | public uint WorldLocX = 0; |
152 | public uint WorldLocY = 0; | 153 | public uint WorldLocY = 0; |
@@ -686,6 +687,20 @@ namespace OpenSim.Framework | |||
686 | config.Set("AllowAlternatePorts", m_allow_alternate_ports.ToString()); | 687 | config.Set("AllowAlternatePorts", m_allow_alternate_ports.ToString()); |
687 | } | 688 | } |
688 | 689 | ||
690 | // ResolveAddress | ||
691 | // | ||
692 | allKeys.Remove("ResolveAddress"); | ||
693 | if (config.Contains("ResolveAddress")) | ||
694 | { | ||
695 | m_resolveAddress = config.GetBoolean("ResolveAddress", false); | ||
696 | } | ||
697 | else | ||
698 | { | ||
699 | m_resolveAddress = Convert.ToBoolean(MainConsole.Instance.CmdPrompt("Resolve hostname to IP on start (for running inside Docker)", "False")); | ||
700 | |||
701 | config.Set("ResolveAddress", m_resolveAddress.ToString()); | ||
702 | } | ||
703 | |||
689 | // ExternalHostName | 704 | // ExternalHostName |
690 | // | 705 | // |
691 | allKeys.Remove("ExternalHostName"); | 706 | allKeys.Remove("ExternalHostName"); |
@@ -706,6 +721,10 @@ namespace OpenSim.Framework | |||
706 | "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}", | 721 | "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}", |
707 | m_externalHostName, name); | 722 | m_externalHostName, name); |
708 | } | 723 | } |
724 | else if (!m_resolveAddress) | ||
725 | { | ||
726 | m_externalHostName = externalName; | ||
727 | } | ||
709 | else | 728 | else |
710 | { | 729 | { |
711 | IPAddress[] addrs = Dns.GetHostAddresses(externalName); | 730 | IPAddress[] addrs = Dns.GetHostAddresses(externalName); |