Update HAProxy documentation (2.6.5)

This commit is contained in:
Simon Legner 2022-09-06 14:35:40 +02:00
parent cf2c992c14
commit d55d41b03c
2 changed files with 13 additions and 8 deletions

View file

@ -388,7 +388,7 @@ credits = [
'https://raw.githubusercontent.com/wycats/handlebars.js/master/LICENSE'
], [
'HAProxy',
'2021 Willy Tarreau, HAProxy contributors',
'2022 Willy Tarreau, HAProxy contributors',
'GPLv2',
'https://raw.githubusercontent.com/haproxy/haproxy/master/LICENSE'
], [

View file

@ -16,18 +16,23 @@ module Docs
options[:follow_links] = false
options[:attribution] = <<-HTML
&copy; 2021 Willy Tarreau, HAProxy contributors<br>
&copy; 2022 Willy Tarreau, HAProxy contributors<br>
Licensed under the GNU General Public License version 2.
HTML
version '2.6' do
self.release = '2.6.5'
self.base_url = "https://docs.haproxy.org/#{self.version}/"
end
version '2.5' do
self.release = '2.5.0'
self.base_url = "https://cbonte.github.io/haproxy-dconv/#{self.version}/"
self.release = '2.5.8'
self.base_url = "https://docs.haproxy.org/#{self.version}/"
end
version '2.4' do
self.release = '2.4.0'
self.base_url = "https://cbonte.github.io/haproxy-dconv/#{self.version}/"
self.release = '2.4.18'
self.base_url = "https://docs.haproxy.org/#{self.version}/"
end
version '2.3' do
@ -66,8 +71,8 @@ module Docs
end
def get_latest_version(opts)
doc = fetch_doc('http://www.haproxy.org', opts)
doc.at_css('table[cols=6]').css('tr')[1].at_css('td').content
doc = fetch_doc('https://www.haproxy.org', opts)
doc.at_css('table[cols=6]').at_css('tr:not(:first-child) > td:first-child:not(:contains("dev"))').content
end
end
end