PhpWord - TemplateProcessor:错误复制模板

I have developed a Laravel app that read a .docx template, populate and save it in pdf format. On my pc and some server it works greatly, but with a new Debian 9 VPS I have a strange error. When I create the template (the PhpWord code try to copy my template from /var/www/myapp/... to /tmp/ ), I have this error:

copy(): php_network_getaddresses: getaddrinfo failed: Name or service not known

This it the line in TemplateProcessor.php that trow the exception:

if (false === copy($documentTemplate, $this->tempDocumentFilename)) {
            throw new CopyFileException($documentTemplate, $this->tempDocumentFilename);
}

Can you help me? I have a Debian 9 VPS, Nginx and PHP 7.2. Thanks!