doufu1950 2014-04-14 22:29
浏览 52
已采纳

如何使用Puppet Apache2模块启用PHP5模块[关闭]

I am using this Apache2 handling Puppet module

https://forge.puppetlabs.com/puppetlabs/apache

When I execute the following code, it successfully installs the virtual host, but it never enables the PHP5 module for Apache2. How do I enable it?

class { 'apache': 
    mpm_module => 'prefork',
}

apache::vhost { 'mysite':
    ...
    xyz
    ...
}

apache::mod { 'php5': }

I also tried to replace the line with:

apache::mod { 'php': }

but that didn't help. The php5 module doesn't get enabled. I have to enable it manually by running a2enmod php5. The documentation doesn't say much about this. Thanks!

  • 写回答

1条回答 默认 最新

  • douaoren4402 2014-04-14 23:16
    关注

    according to the README, the apache::mod type should only be used for modules that do not have a specific apache::mod:: class. This is not true for PHP, see another part of the same README. Therefor, the correct manifest would be

    include apache::mod::php
    

    These semi-official Puppet Labs modules are generally a good resource.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 delta降尺度计算的一些细节,有偿
  • ¥15 Arduino红外遥控代码有问题
  • ¥15 数值计算离散正交多项式
  • ¥30 数值计算均差系数编程
  • ¥15 redis-full-check比较 两个集群的数据出错
  • ¥15 Matlab编程问题
  • ¥15 训练的多模态特征融合模型准确度很低怎么办
  • ¥15 kylin启动报错log4j类冲突
  • ¥15 超声波模块测距控制点灯,灯的闪烁很不稳定,经过调试发现测的距离偏大
  • ¥15 import arcpy出现importing _arcgisscripting 找不到相关程序