loolwsd: copy /etc/resolv.conf in the jail

Because sometimes the hostname is not resolved
This commit is contained in:
Mihai Varga 2015-09-04 18:43:47 +03:00
parent 159e668b01
commit 515e6f7fea

View file

@ -894,6 +894,12 @@ void LOOLWSD::desktopMain()
linkOrCopy(LOOLWSD::sysTemplate, jail);
linkOrCopy(LOOLWSD::loTemplate, jailLOInstallation);
// We need this because sometimes the hostname is not resolved
File resolv("/etc/resolv.conf");
if (resolv.exists())
{
resolv.copyTo(Path(jail, "/etc").toString());
}
#ifdef __linux
// Create the urandom and random devices
File(Path(jail, "/dev")).createDirectory();