Skip to content

Commit

Permalink
Wait for 120s before checking jira is up and running
Browse files Browse the repository at this point in the history
  • Loading branch information
danifr committed Nov 6, 2023
1 parent 43bb4d1 commit 4cba567
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
12 changes: 6 additions & 6 deletions spec/acceptance/default_parameters_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,17 +49,17 @@ class { 'jira':
# jira just takes *ages* to start up :-(
wget_cmd = 'wget -q --tries=24 --retry-connrefused --read-timeout=10 localhost:8080'
apply_manifest(pp, catch_failures: true)
sleep 60
sleep SLEEP_SECONDS
shell wget_cmd, acceptable_exit_codes: [0, 8]
sleep 60
sleep SLEEP_SECONDS
shell wget_cmd, acceptable_exit_codes: [0, 8]
sleep 60
sleep SLEEP_SECONDS
apply_manifest(pp_upgrade, catch_failures: true)
sleep 60
sleep SLEEP_SECONDS
shell wget_cmd, acceptable_exit_codes: [0, 8]
sleep 60
sleep SLEEP_SECONDS
shell wget_cmd, acceptable_exit_codes: [0, 8]
sleep 60
sleep SLEEP_SECONDS
apply_manifest(pp_upgrade, catch_failures: true)
end

Expand Down
6 changes: 3 additions & 3 deletions spec/acceptance/mysql_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,11 @@ class { 'jira':

wget_cmd = 'wget -q --tries=24 --retry-connrefused --read-timeout=10 --no-check-certificate localhost:8081'
apply_manifest(pp, catch_failures: true)
sleep 60
sleep SLEEP_SECONDS
shell wget_cmd, acceptable_exit_codes: [0, 8]
sleep 60
sleep SLEEP_SECONDS
shell wget_cmd, acceptable_exit_codes: [0, 8]
sleep 60
sleep SLEEP_SECONDS
apply_manifest(pp, catch_changes: true)
end

Expand Down
2 changes: 2 additions & 0 deletions spec/support/acceptance/constants.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@
FILENAME_DBCONFIG_XML = '/home/jira/dbconfig.xml'
FILENAME_CLUSTER_PROPS = '/home/jira/cluster.properties'
FILENAME_JIRA_CONFIG_PROPS = '/home/jira/jira-config.properties'

SLEEP_SECONDS=120

Check failure on line 20 in spec/support/acceptance/constants.rb

View workflow job for this annotation

GitHub Actions / Puppet / Static validations

Layout/SpaceAroundOperators: Surrounding space missing for operator `=`. (https://rubystyle.guide#spaces-operators)

0 comments on commit 4cba567

Please sign in to comment.