GPG fixes

This commit is contained in:
Johan Björklund 2024-11-21 10:53:08 +01:00
parent ac668fd1d1
commit 8a1bce76b9
Signed by untrusted user: bjorklund
GPG key ID: 5E8401339C7F5037

View file

@ -310,13 +310,8 @@ class soc::intelmq(
if lookup('gnupg.privkey', undef, undef, undef) != undef {
sunet::snippets::secret_file { "/opt/intelmq/.gnupg/${privkey}.asc":
hiera_key => 'gnupg.privkey'
}
file { "/opt/intelmq/.gnupg/${privkey}.asc":
ensure => present,
replace => false,
onwer => 'intelmq',
group => 'intelmq',
mode => '0500',
owner => 'intelmq',
group => 'intelmq',
}
exec { 'Import private gpg key':
command => "sudo -u intelmq /usr/bin/gpg -import /opt/intelmq/.gnupg/${privkey}.asc",