Merge "Add mirror01.iad.rax.o.o"
This commit is contained in:
commit
3f372b52cc
@ -443,6 +443,7 @@ cacti_hosts:
|
||||
- mirror.dfw.rax.openstack.org
|
||||
- mirror.gra1.ovh.openstack.org
|
||||
- mirror.iad.rax.openstack.org
|
||||
- mirror01.iad.rax.openstack.org
|
||||
- mirror.kna1.citycloud.openstack.org
|
||||
- mirror.la1.citycloud.openstack.org
|
||||
- mirror.lon1.citycloud.openstack.org
|
||||
|
@ -611,7 +611,8 @@ node 'mirror-update.openstack.org' {
|
||||
|
||||
# Machines in each region to serve AFS mirrors.
|
||||
# Node-OS: trusty
|
||||
node /^mirror\..*\.openstack\.org$/ {
|
||||
# Node-OS: xenial
|
||||
node /^mirror\d*\..*\.openstack\.org$/ {
|
||||
$group = "mirror"
|
||||
|
||||
class { 'openstack_project::server':
|
||||
|
@ -4,6 +4,16 @@ class openstack_project::mirror (
|
||||
$vhost_name = $::fqdn,
|
||||
) {
|
||||
|
||||
# Some hosts are mirror01, but we need the host to respond to
|
||||
# "mirror." Re-evaluate this if we end up doing multiple
|
||||
# mirrors/load balancing etc.
|
||||
$alias_name = regsubst($vhost_name, 'mirror\d*\.', 'mirror.')
|
||||
if $alias_name != $vhost_name {
|
||||
$serveraliases = [$alias_name]
|
||||
} else {
|
||||
$serveraliases = undef
|
||||
}
|
||||
|
||||
$mirror_root = '/afs/openstack.org/mirror'
|
||||
$pypi_root = "${mirror_root}/pypi"
|
||||
$wheel_root = "${mirror_root}/wheel"
|
||||
@ -283,6 +293,7 @@ class openstack_project::mirror (
|
||||
priority => '50',
|
||||
docroot => "${www_root}",
|
||||
template => 'openstack_project/mirror.vhost.erb',
|
||||
serveraliases => $serveraliases,
|
||||
require => [
|
||||
File["${www_root}"],
|
||||
]
|
||||
|
@ -14,10 +14,12 @@ NameVirtualHost <%= @vhost_name %>:8081
|
||||
<VirtualHost <%= @vhost_name %>:<%= @port %>>
|
||||
ServerName <%= @srvname %>
|
||||
<% if @serveraliases.is_a? Array -%>
|
||||
<% @serveraliases.each do |name| -%><%= " ServerAlias #{name}\n" %><% end -%>
|
||||
<% @serveraliases.each do |name| -%>
|
||||
<%= " ServerAlias #{name}\n" %>
|
||||
<% end %>
|
||||
<% elsif @serveraliases != nil -%>
|
||||
<%= " ServerAlias #{@serveraliases}" -%>
|
||||
<% end -%>
|
||||
<% end %>
|
||||
DocumentRoot <%= @docroot %>
|
||||
<Directory <%= @docroot %>>
|
||||
Options <%= @options %>
|
||||
@ -93,6 +95,13 @@ NameVirtualHost <%= @vhost_name %>:8081
|
||||
|
||||
<VirtualHost <%= @vhost_name %>:8080>
|
||||
ServerName <%= @srvname %>:8080
|
||||
<% if @serveraliases.is_a? Array -%>
|
||||
<% @serveraliases.each do |name| -%>
|
||||
<%= " ServerAlias #{name}:8080\n" %>
|
||||
<% end %>
|
||||
<% elsif @serveraliases != nil -%>
|
||||
<%= " ServerAlias #{@serveraliases}:8080" -%>
|
||||
<% end %>
|
||||
|
||||
# Disable directory listing by default.
|
||||
<Directory />
|
||||
@ -188,6 +197,13 @@ NameVirtualHost <%= @vhost_name %>:8081
|
||||
|
||||
<VirtualHost <%= @vhost_name %>:8081>
|
||||
ServerName <%= @srvname %>:8081
|
||||
<% if @serveraliases.is_a? Array -%>
|
||||
<% @serveraliases.each do |name| -%>
|
||||
<%= " ServerAlias #{name}:8081\n" %>
|
||||
<% end %>
|
||||
<% elsif @serveraliases != nil -%>
|
||||
<%= " ServerAlias #{@serveraliases}:8081" -%>
|
||||
<% end %>
|
||||
|
||||
# Disable directory listing by default.
|
||||
<Directory />
|
||||
|
Loading…
Reference in New Issue
Block a user