Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DEV-1141: Add Prometheus::Tiny::Shared for all HT perl places #697

Merged
merged 2 commits into from
Jul 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions manifests/profile/hathitrust/dependencies.pp
Original file line number Diff line number Diff line change
Expand Up @@ -65,4 +65,10 @@

ensure_packages(['mariadb-client'])

file { '/usr/local/bin/catprocio':
ensure => 'present',
content => file('nebula/imgsrv/catprocio'),
mode => '0755',
}

}
7 changes: 0 additions & 7 deletions manifests/profile/hathitrust/imgsrv.pp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@
}

package { 'libfcgi-bin': }
nebula::cpan { 'Prometheus::Tiny::Shared': }

cron { 'imgsrv responsiveness check':
command => '/usr/local/bin/check_imgsrv > /dev/null 2>&1',
Expand All @@ -78,12 +77,6 @@
source => "https://${http_files}/ae-utils/bins/startup_app"
}

file { '/usr/local/bin/catprocio':
ensure => 'present',
content => file('nebula/imgsrv/catprocio'),
mode => '0755',
}

file { '/etc/sudoers.d/imgsrv-catprocio':
ensure => 'present',
content => 'nobody ALL=(root) NOPASSWD: /usr/local/bin/catprocio'
Expand Down
3 changes: 2 additions & 1 deletion manifests/profile/hathitrust/perl.pp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,8 @@
'Noid',
'MARC::Record',
'MARC::File::XML',
'MARC::File::MiJ']:
'MARC::File::MiJ',
'Prometheus::Tiny::Shared']:
}

}
5 changes: 5 additions & 0 deletions manifests/profile/hathitrust/slip.pp
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,9 @@
class nebula::profile::hathitrust::slip (
) {
nebula::usergroup { 'slip': }

file { '/etc/sudoers.d/slip-catprocio':
ensure => 'present',
content => 'slip ALL=(root) NOPASSWD: /usr/local/bin/catprocio'
}
}
1 change: 1 addition & 0 deletions spec/classes/profile/hathitrust/dependencies_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
it { is_expected.to contain_package('mariadb-client') }
end

it { is_expected.to contain_file('/usr/local/bin/catprocio') }
end
end
end
2 changes: 0 additions & 2 deletions spec/classes/profile/hathitrust/imgsrv_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,13 @@

it { is_expected.to contain_service('imgsrv') }
it { is_expected.to contain_package('libfcgi-bin') }
it { is_expected.to contain_nebula__cpan('Prometheus::Tiny::Shared') }

it { is_expected.to contain_file('/usr/local/bin/startup_imgsrv').with_content(%r{^SDRROOT=/sdrroot$}) }
it { is_expected.to contain_file('/usr/local/bin/startup_imgsrv').with_content(%r{^NPROC=10$}) }
it { is_expected.to contain_file('/usr/local/bin/startup_imgsrv').with_content(%r{^BIND=127.0.0.1:31028}) }

it { is_expected.to contain_file('/etc/systemd/system/imgsrv.service').with_content(%r{ExecStart=/usr/local/bin/startup_imgsrv}) }

it { is_expected.to contain_file('/usr/local/bin/catprocio') }
it { is_expected.to contain_file('/etc/sudoers.d/imgsrv-catprocio') }
end
end
Expand Down
2 changes: 2 additions & 0 deletions spec/classes/profile/hathitrust/slip_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
it { is_expected.to compile }

it { is_expected.to contain_nebula__usergroup('slip') }

it { is_expected.to contain_file('/etc/sudoers.d/slip-catprocio') }
end
end
end
2 changes: 2 additions & 0 deletions spec/classes/role/htvm_webhost_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@
# not specified explicitly - realized through Nebula::Usergroup[htprod]
it { is_expected.to contain_user('htingest') }
it { is_expected.to contain_user('htweb') }

it { is_expected.to contain_nebula__cpan('Prometheus::Tiny::Shared') }
end
end
end