* Attempt number 1 * Fix rack_attack specs * Fix users_searches_users spec * Fix display_users_search_spec * Fix comment typo * Remove search:destroy task from cypress * Remove port 9300 from gitpod * Stub response in attack_spec
20 lines
671 B
Bash
Executable file
20 lines
671 B
Bash
Executable file
#!/bin/bash
|
|
|
|
notify () {
|
|
FAILED_COMMAND="$(caller): ${BASH_COMMAND}" \
|
|
bundle exec rails runner "ReleasePhaseNotifier.ping_slack"
|
|
}
|
|
|
|
trap notify ERR
|
|
|
|
# enable echo mode (-x) and exit on error (-e)
|
|
# -E ensures that ERR traps get inherited by functions, command substitutions, and subshell environments.
|
|
set -Eex
|
|
|
|
# abort release if deploy status equals "blocked"
|
|
[[ $DEPLOY_STATUS = "blocked" ]] && echo "Deploy blocked" && exit 1
|
|
|
|
# runs migration for Postgres and boots the app to check there are no errors
|
|
STATEMENT_TIMEOUT=4500000 bundle exec rails app_initializer:setup
|
|
bundle exec rake fastly:update_configs
|
|
bundle exec rails runner "puts 'app load success'"
|