Skip to content

Commit

Permalink
(Puppetfile) Merge branch 'production' into IT-5850-bump-systemd
Browse files Browse the repository at this point in the history
  • Loading branch information
badenerb committed Dec 19, 2024
2 parents e7bbed5 + 092ff7d commit e1824c0
Show file tree
Hide file tree
Showing 4 changed files with 121 additions and 0 deletions.
32 changes: 32 additions & 0 deletions hieradata/node/hvac.cp.lsst.org.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
nm::connections:
ens192:
content:
connection:
id: "ens192"
uuid: "5c4da295-6537-35c0-bcbb-44ac7c3e6f96"
type: "ethernet"
interface-name: "ens192"
ethernet: {}
ipv4:
address1: "139.229.160.81/24,139.229.160.254"
dns: "139.229.135.53;139.229.135.54;139.229.135.55;"
dns-search: "cp.lsst.org;"
method: "manual"
ipv6:
method: "disabled"
proxy: {}
ens224:
content:
connection:
id: "ens224"
uuid: "f5503f66-ba6c-3c41-9e03-cbc7ed281590"
type: "ethernet"
interface-name: "ens224"
ethernet: {}
ipv4:
address1: "10.255.211.48/25"
method: "manual"
ipv6:
method: "disabled"
proxy: {}
7 changes: 7 additions & 0 deletions hieradata/role/niagara.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
classes:
- "profile::core::common"

sudo::configs:
niagara_sudoers:
content: "%niagara ALL=(ALL) NOPASSWD: /usr/bin/niagaradctl"
53 changes: 53 additions & 0 deletions spec/hosts/nodes/hvac.cp.lsst.org_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# frozen_string_literal: true

require 'spec_helper'

describe 'hvac.cp.lsst.org', :sitepp do
on_supported_os.each do |os, os_facts|
next unless os =~ %r{almalinux-9-x86_64}

context "on #{os}" do
let(:facts) do
lsst_override_facts(os_facts,
is_virtual: true,
virtual: 'vmware',
dmi: {
'product' => {
'name' => 'VMware7,1',
},
})
end
let(:node_params) do
{
role: 'generic',
site: 'cp',
}
end

it { is_expected.to compile.with_all_deps }

include_context 'with nm interface'
it { is_expected.to have_nm__connection_resource_count(2) }

context 'with ens192' do
let(:interface) { 'ens192' }

it_behaves_like 'nm enabled interface'
it_behaves_like 'nm ethernet interface'
it { expect(nm_keyfile['ipv4']['address1']).to eq('139.229.160.81/24,139.229.160.254') }
it { expect(nm_keyfile['ipv4']['dns']).to eq('139.229.135.53;139.229.135.54;139.229.135.55;') }
it { expect(nm_keyfile['ipv4']['dns-search']).to eq('cp.lsst.org;') }
it { expect(nm_keyfile['ipv4']['method']).to eq('manual') }
end

context 'with ens224' do
let(:interface) { 'ens224' }

it_behaves_like 'nm enabled interface'
it_behaves_like 'nm ethernet interface'
it { expect(nm_keyfile['ipv4']['address1']).to eq('10.255.211.48/25') }
it { expect(nm_keyfile['ipv4']['method']).to eq('manual') }
end
end # on os
end # on_supported_os
end
29 changes: 29 additions & 0 deletions spec/hosts/roles/niagara_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# frozen_string_literal: true

require 'spec_helper'

role = 'niagara'

describe "#{role} role" do
on_supported_os.each do |os, os_facts|
next unless os =~ %r{almalinux-9-x86_64}

context "on #{os}" do
lsst_sites.each do |site|
describe "#{role}.#{site}.lsst.org", :sitepp do
let(:node_params) do
{
role:,
site:,
}
end
let(:facts) { lsst_override_facts(os_facts) }

it { is_expected.to compile.with_all_deps }

include_examples('common', os_facts:, site:)
end # host
end # lsst_sites
end # on os
end # on_supported_os
end # role

0 comments on commit e1824c0

Please sign in to comment.