podmanrunner/manifests/runner.pp

46 lines
1,008 B
ObjectPascal
Raw Normal View History

# Class for forgeo action runner.
class podmanrunner::runner (
Integer $replicas = 2,
)
{
2024-01-18 14:03:47 +00:00
user { 'podmanuser':
ensure => present,
2024-01-18 14:03:47 +00:00
home => '/opt/podmanuser',
shell => '/usr/sbin/nologin',
uid => '1001',
managehome => true,
}
package { 'podman':
ensure => installed,
provider => apt,
}
package { 'systemd-container':
ensure => installed,
provider => apt,
}
file { '/opt/podmanuser/docker-compose.yaml':
ensure => file,
content => template('podmanrunner/docker-compose.yaml.erb'),
owner => 'podmanuser',
group => 'podmanuser',
mode => '0600',
}
2024-01-18 15:03:40 +00:00
file { '/opt/podmanuser/bin':
ensure => directory,
mode => '0700',
owner => 'podmanuser',
group => 'podmanuser',
}
2024-01-18 15:03:40 +00:00
file { '/opt/podmanuser/bin/podman-compose':
ensure => file,
mode => '500',
source => 'puppet:///modules/podmanrunner/podman-compose',
2024-01-18 15:27:32 +00:00
owner => 'podmanuser',
group => 'podmanuser',
}
}