无法从环境生产源检索信息

 手机用户2502925587 发布于 2023-01-09 12:43

我在我的一个流浪项目中使用木偶作为我的供应者.我正在尝试为自定义bash_profile添加模块.

module_path对木偶被设置为:

 puppet.module_path = "puppet/modules"

我的bash_profile模块的类看起来像这样:

class bash_profile
{
    file
    {
        "/home/vagrant/bash_profile":
            ensure => present,
            source => "puppet:///modules/bash_profile/files/bash_profile"
    }
}

这是我的木偶结构的文件结构:

puppet
| manifests
| | phpbase.pp // my main manifest file that has includes for modules
| modules
| | bash_profile
| | | files
| | | | bash_profile // the actual bash_profile file I want to ensure is present on my VM
| | | manifests
| | | | init.pp // the init file included for the bash_profile class

当我为vagrant运行配置时,我收到错误

错误:/ Stage [main]/Bash_profile/File [/ home/vagrant/bash_profile]:无法评估:无法从环境生产源中检索信息:/// modules/bash_profile/files/bash_profile at/tmp /vagrant-puppet-1/modules-0/bash_profile/manifests/init.pp:8

我不确定为什么它无法检索信息.路径似乎是正确的.任何人都能看到我错过的东西吗?

1 个回答
  • 是的,您不应该files/在URL中包含文字.相反,它应该是

    puppet:///modules/bash_profile/bash_profile
    

    2023-01-09 12:45 回答
撰写答案
今天,你开发时遇到什么问题呢?
立即提问
热门标签
PHP1.CN | 中国最专业的PHP中文社区 | PNG素材下载 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有