Saltstack Official Nginx Formula
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
755B

  1. # frozen_string_literal: true
  2. control 'Nginx service' do
  3. title 'should be running and enabled'
  4. describe service('nginx') do
  5. it { should be_enabled }
  6. it { should be_running }
  7. end
  8. end
  9. control 'Passenger module' do
  10. title 'should be running and enabled'
  11. describe 'Passenger engine' do
  12. it 'passenger-config should say configuration "looks good"' do
  13. expect(command(
  14. '/usr/bin/passenger-config validate-install --auto'
  15. ).stdout).to match(/looks good/)
  16. end
  17. it 'passenger-memory-stats should return Passenger stats' do
  18. expect(command('/usr/sbin/passenger-memory-stats').stdout).to match(
  19. %r{nginx: master process /usr/sbin/nginx.*Passenger watchdog.*Passenger core.*}m
  20. )
  21. end
  22. end
  23. end