Skip to content

Commit a858341

Browse files
committed
looks like facter virtual doesnt work in docker on gha
1 parent aeaa7c9 commit a858341

File tree

2 files changed

+23
-28
lines changed

2 files changed

+23
-28
lines changed

spec/support/acceptance/shared/puppetdb.rb

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,14 @@
1616
gpgkey => "file:///etc/pki/rpm-gpg/${gpg_key_file}",
1717
}
1818
19-
if $facts['virtual'] == 'docker' {
20-
# Work-around EL systemd in docker bug affecting forked services
21-
file_line { 'puppetdb-unit-remove-pidfile':
22-
path => '/lib/systemd/system/puppetdb.service',
23-
line => '#PIDFile=/run/puppetlabs/puppetdb/puppetdb.pid',
24-
match => '^PIDFile.*',
25-
append_on_no_match => false,
26-
require => Package['puppetdb'],
27-
notify => Service['puppetdb'],
28-
}
19+
# Work-around EL systemd in docker bug affecting forked services
20+
file_line { 'puppetdb-unit-remove-pidfile':
21+
path => '/lib/systemd/system/puppetdb.service',
22+
line => '#PIDFile=/run/puppetlabs/puppetdb/puppetdb.pid',
23+
match => '^PIDFile.*',
24+
append_on_no_match => false,
25+
require => Package['puppetdb'],
26+
notify => Service['puppetdb'],
2927
}
3028
}
3129

spec/support/acceptance/shared/puppetserver.pp

Lines changed: 15 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -25,23 +25,21 @@
2525
-> Package <| tag == 'postgresql' |>
2626
}
2727

28-
if $facts['virtual'] == 'docker' {
29-
# Work-around EL systemd in docker with cgroupsv1? issue and forked services
30-
# Without this, the puppet agent will stall for 300 seconds waiting for
31-
# the service to start... then miserably fail.
32-
# systemd error message:
33-
# New main PID 1411 does not belong to service, and PID file is not
34-
# owned by root. Refusing.
35-
# PIDFile is not needed, but it cannot be reset by a drop-in, therefor the
36-
# original unit must be modified
37-
file_line { 'puppetserver-unit-remove-pidfile':
38-
path => '/lib/systemd/system/puppetserver.service',
39-
line => '#PIDFile=/run/puppetlabs/puppetserver.pid',
40-
match => '^PIDFile.*',
41-
append_on_no_match => false,
42-
require => Package['puppetserver'],
43-
notify => Service['puppetserver'],
44-
}
28+
# Work-around EL systemd in docker with cgroupsv1? issue and forked services
29+
# Without this, the puppet agent will stall for 300 seconds waiting for
30+
# the service to start... then miserably fail.
31+
# systemd error message:
32+
# New main PID 1411 does not belong to service, and PID file is not
33+
# owned by root. Refusing.
34+
# PIDFile is not needed, but it cannot be reset by a drop-in, therefor the
35+
# original unit must be modified
36+
file_line { 'puppetserver-unit-remove-pidfile':
37+
path => '/lib/systemd/system/puppetserver.service',
38+
line => '#PIDFile=/run/puppetlabs/puppetserver.pid',
39+
match => '^PIDFile.*',
40+
append_on_no_match => false,
41+
require => Package['puppetserver'],
42+
notify => Service['puppetserver'],
4543
}
4644
}
4745

@@ -69,7 +67,6 @@
6967
context => "/files${sysconfdir}/puppetserver",
7068
changes => [
7169
'set JAVA_ARGS \'"-Xms512m -Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger"\'',
72-
"set START_TIMEOUT '30'",
7370
],
7471
}
7572
-> service { 'puppetserver':

0 commit comments

Comments
 (0)