From b5d811ad2069d661ad47a16a9c7d06a691c13f84 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Sun, 19 Sep 2021 10:24:18 +0100 Subject: [PATCH] Add equinix-dub role --- .../templates/default/shorewall-zones.erb | 1 + roles/equinix-dub.rb | 47 +++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 roles/equinix-dub.rb diff --git a/cookbooks/networking/templates/default/shorewall-zones.erb b/cookbooks/networking/templates/default/shorewall-zones.erb index 72e004713..f4d7a4772 100644 --- a/cookbooks/networking/templates/default/shorewall-zones.erb +++ b/cookbooks/networking/templates/default/shorewall-zones.erb @@ -9,3 +9,4 @@ osm:net <%= @type %> ucl:osm <%= @type %> ams:osm <%= @type %> bm:osm <%= @type %> +dub:osm <%= @type %> diff --git a/roles/equinix-dub.rb b/roles/equinix-dub.rb new file mode 100644 index 000000000..8bda3a86a --- /dev/null +++ b/roles/equinix-dub.rb @@ -0,0 +1,47 @@ +name "equinix-dub" +description "Role applied to all servers at Equinix Dublin" + +default_attributes( + :networking => { + :roles => { + :internal => { + :inet => { + :prefix => "20", + :gateway => "10.0.64.2", + :routes => { + "10.0.0.0/8" => { :via => "10.0.64.2" } + } + } + }, + :external => { + :zone => "dub", + :inet => { + :prefix => "27", + :gateway => "184.104.226.97" + }, + :inet6 => { + :prefix => "64", + :gateway => "2001:470:1:b3b::1" + } + } + } + }, + :web => { + :fileserver => "fafnir", + :readonly_database_host => "snap-03.dub.openstreetmap.org" + } +) + +override_attributes( + :networking => { + :nameservers => ["10.0.64.2", "1.1.1.1", "1.0.0.1"], + :search => ["dub.openstreetmap.org", "openstreetmap.org"] + }, + :ntp => { + :servers => ["0.ie.pool.ntp.org", "1.ie.pool.ntp.org", "europe.pool.ntp.org"] + } +) + +run_list( + "role[ie]" +) -- 2.39.5