Repos with recipes to deploy some infrastructure services
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.
 
 

33 lines
981 B

  1. debian_os = ['debian', 'ubuntu']
  2. rhel_os = ['redhat', 'centos']
  3. def test_repo_file(host):
  4. f = None
  5. if host.system_info.distribution.lower() in debian_os:
  6. f = host.file('/etc/apt/sources.list.d/powerdns-auth-master.list')
  7. if host.system_info.distribution.lower() in rhel_os:
  8. f = host.file('/etc/yum.repos.d/powerdns-auth-master.repo')
  9. assert f.exists
  10. assert f.user == 'root'
  11. assert f.group == 'root'
  12. def test_pdns_repo(host):
  13. f = None
  14. if host.system_info.distribution.lower() in debian_os:
  15. f = host.file('/etc/apt/sources.list.d/powerdns-auth-master.list')
  16. if host.system_info.distribution.lower() in rhel_os:
  17. f = host.file('/etc/yum.repos.d/powerdns-auth-master.repo')
  18. assert f.exists
  19. assert f.contains('auth-master')
  20. def test_pdns_version(host):
  21. cmd = host.run('/usr/sbin/pdns_server --version')
  22. assert 'PowerDNS Authoritative Server 0.0.' in cmd.stderr