docker.rb 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. module Docs
  2. class Docker < UrlScraper
  3. self.type = 'docker'
  4. self.links = {
  5. home: 'https://docker.com/',
  6. code: 'https://github.com/docker/docker'
  7. }
  8. html_filters.push 'docker/entries', 'docker/clean_html'
  9. options[:container] = '#docs'
  10. options[:trailing_slash] = true
  11. options[:only_patterns] = [
  12. /\Aengine\//,
  13. /\Acompose\//,
  14. /\Amachine\//,
  15. /\Aswarm\//
  16. ]
  17. options[:skip] = %w(swarm/scheduler/)
  18. options[:replace_paths] = {
  19. 'engine/installation/ubuntulinux/' => 'engine/installation/linux/ubuntulinux/'
  20. }
  21. options[:attribution] = <<-HTML
  22. &copy; 2013&ndash;2016 Docker, Inc.<br>
  23. Licensed under the Apache License, Version 2.0.<br>
  24. Docker and the Docker logo are trademarks or registered trademarks of Docker, Inc. in the United States and/or other countries.<br>
  25. Docker, Inc. and other parties may also have trademark rights in other terms used herein.
  26. HTML
  27. version '1.11' do
  28. self.release = '1.11'
  29. self.base_url = "https://docs.docker.com/v#{self.version}/"
  30. end
  31. version '1.10' do
  32. self.release = '1.10'
  33. self.base_url = "https://docs.docker.com/v#{self.version}/"
  34. end
  35. end
  36. end