Commit 963dccb4 authored by Matteo Melli's avatar Matteo Melli
Browse files

Created database wrangler runbook menu and steps

parent 3d7aa2bd
source_vars
.project
\ No newline at end of file
......@@ -8,10 +8,27 @@ function do_step(){
}
function do_menu(){
echo "echo $options"
while read opt
IF=''
select step in $(print_steps)
do
echo $opt
done < <(echo $options)
script="$(echo "$step"|cut -d ' ' -f 1)"
echo -n "Press a key to execute $script"
read
do_step "$script"
done
}
function print_steps(){
echo "001_check_gcp_replication_delay Ensure the prospective failover target in GCP is up to date"
echo "002_disable-automatic-failover Disable chef on all nodes and shut down repmgr"
#This step should convert old master to headless standby
echo "003_forbid-writes-to-current-master Forbid writes to the currect master (Azure) – do not allow any connections except replication and administrative (local via socket) ones."
echo "004_perform-regular-switchover Perform regular switchover to the main replica on GCP"
echo "005_check_gcp_has_master Check the database is now read-write"
echo "006_configure-pgbouncer-for-gcp Configure pgbouncer to point to new master in GCP"
echo "007_convert-wal-e-node-to-standby Convert the WAL-E node to a standby node in repmgr"
echo "008_ensure-priority-is-updated-in-repmgr Ensure priority is updated in repmgr configuration"
echo "009_update_chef_cookbook Update in chef cookbooks by removing the setting entirely"
echo "010_update_master_repmgr_priority Update in the running database (On the primary server)"
echo "011_reduce_statement_timeout Reduce statement_timeout to 15s"
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment