1

我正在尝试使用内置文件服务器将文件从 puppet master 递归传输到我的代理。

我有一个名为“环境”的文件夹名称,它没有转移给我的代理。相反,我收到以下错误

 Error: Could not set 'file' on ensure: Error 404 on SERVER: {"message":"Not Found: file1.txt is not a known environment","issue_kind":"RESOURCE_NOT_FOUND"}
 Error: Could not set 'file' on ensure: Error 404 on SERVER: {"message":"Not Found: file1.txt is not a known environment","issue_kind":"RESOURCE_NOT_FOUND"}
 Wrapped exception:
 Error 404 on SERVER: {"message":"Not Found: file1.txt is not a known environment","issue_kind":"RESOURCE_NOT_FOUND"}
 Error: /Stage[main]/Platform::Configuration::Test1/File[/opt/pe-platform-test/test2/file1.txt]/ensure: change from absent to file failed: Could not set 'file' on ensure: Error 404 on SERVER: {"message":"Not Found: file1.txt is not a known environment","issue_kind":"RESOURCE_NOT_FOUND"}

我的实际代码如下

class platform::configuration::test1 {

  file { "/opt/pe-platform-test/test2":
    ensure  => "directory",
    source  =>  "puppet://puppetmaster.sample.net/puppet_plat_shared/environment",
    source_permissions=>"use",
    ignore  => [".svn"],
    replace => "true",
    recurse => "remote",
  }

}
4

1 回答 1

1

“环境”一词是 Puppet 4.x 中的保留字,您可以尝试将源代码用单引号括起来或更改目录名称?

于 2016-03-04T03:14:51.820 回答