Moved project directories and files to an empty local repo
This commit is contained in:
28
PostgreSQL_Database/nuke_n_pave.sh
Executable file
28
PostgreSQL_Database/nuke_n_pave.sh
Executable file
@@ -0,0 +1,28 @@
|
||||
#!/bin/bash
|
||||
|
||||
#
|
||||
# Script to re-initialise the HPR2 database then rebuild it from the local
|
||||
# MySQL copy (and ia.db for the IA parts). Also updates shows with multiple
|
||||
# hosts by adding the missing hosts.
|
||||
#
|
||||
|
||||
#
|
||||
# Directories
|
||||
#
|
||||
BASEDIR="$HOME/HPR/PostgreSQL_Database"
|
||||
cd "$BASEDIR" || { echo "Failed to cd to $BASEDIR"; exit 1; }
|
||||
|
||||
#
|
||||
# Drops all tables, etc and re-creates them
|
||||
#
|
||||
psql -U hpradmin HPR2 < hpr_schema_2.pgsql
|
||||
|
||||
#
|
||||
# Does all phases in order by default
|
||||
#
|
||||
./copy_mysql_pg_2 -verb
|
||||
|
||||
#
|
||||
# Adds in all the double hosts we know about at the moment
|
||||
#
|
||||
./update_multi-host_shows.sh
|
Reference in New Issue
Block a user