diff --git a/modules/linux_packages/manifests/linux_tools.pp b/modules/linux_packages/manifests/linux_tools.pp new file mode 100644 index 000000000..38e63f660 --- /dev/null +++ b/modules/linux_packages/manifests/linux_tools.pp @@ -0,0 +1,11 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +class linux_packages::linux_tools { + + package { 'linux-tools-generic': + ensure => present, + } + +} diff --git a/modules/roles_profiles/manifests/profiles/linux_perf_profiling.pp b/modules/roles_profiles/manifests/profiles/linux_perf_profiling.pp new file mode 100644 index 000000000..7d075e312 --- /dev/null +++ b/modules/roles_profiles/manifests/profiles/linux_perf_profiling.pp @@ -0,0 +1,17 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +# Installs the linux-tools package (provides `perf`) and grants cltbld +# sudo access to run it. Used by Linux talos roles to support performance +# profiling investigations (bug 2031822). +class roles_profiles::profiles::linux_perf_profiling { + + require linux_packages::linux_tools + + sudo::custom { 'allow_cltbld_perf': + user => 'cltbld', + command => '/usr/bin/perf', + } + +} diff --git a/modules/roles_profiles/manifests/roles/gecko_t_linux_2404_talos.pp b/modules/roles_profiles/manifests/roles/gecko_t_linux_2404_talos.pp index 4e07682d5..4bc3a9bba 100644 --- a/modules/roles_profiles/manifests/roles/gecko_t_linux_2404_talos.pp +++ b/modules/roles_profiles/manifests/roles/gecko_t_linux_2404_talos.pp @@ -18,4 +18,7 @@ # talos stuff include roles_profiles::profiles::gecko_t_linux_2404_talos_generic_worker + + # perf profiling support (bug 2031822) + include roles_profiles::profiles::linux_perf_profiling } diff --git a/modules/roles_profiles/manifests/roles/gecko_t_linux_talos.pp b/modules/roles_profiles/manifests/roles/gecko_t_linux_talos.pp index 4c31ffc77..8779dffb9 100644 --- a/modules/roles_profiles/manifests/roles/gecko_t_linux_talos.pp +++ b/modules/roles_profiles/manifests/roles/gecko_t_linux_talos.pp @@ -19,4 +19,7 @@ # talos stuff include ::roles_profiles::profiles::gecko_t_linux_talos_generic_worker + + # perf profiling support (bug 2031822) + include ::roles_profiles::profiles::linux_perf_profiling }