Saltstack Official PHP Formula
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

47 líneas
1.0KB

  1. control 'Php configuration' do
  2. title 'should match desired lines'
  3. def test_debian
  4. describe file('/etc/php/5.6/fpm/pool.d/radius-admin.conf') do
  5. its('content') { should include '[radius-admin]' }
  6. its('content') { should include 'php_admin_value[date.timezone] = Europe/Paris' }
  7. end
  8. describe file('/etc/php/7.3/fpm/pool.d/ldap-admin.conf') do
  9. its('content') { should include '[ldap-admin]' }
  10. its('content') { should include 'php_admin_value[date.timezone] = Europe/Paris' }
  11. end
  12. describe file('/etc/php/5.6/fpm/php.ini') do
  13. its('content') { should include 'date.timezone = Europe/Paris' }
  14. end
  15. describe file('/etc/php/7.3/fpm/php.ini') do
  16. its('content') { should include 'date.timezone = Europe/Paris' }
  17. end
  18. end
  19. def test_ubuntu
  20. end
  21. def test_redhat
  22. end
  23. def test_suse
  24. end
  25. case os[:family]
  26. when 'debian'
  27. case os[:name]
  28. when 'ubuntu'
  29. test_ubuntu
  30. when 'debian'
  31. test_debian
  32. end
  33. when 'redhat', 'fedora'
  34. test_redhat
  35. when 'suse'
  36. test_suse
  37. end
  38. end