Browse Source

moved variables in solr_import.sh

main
Simon Bowie 2 years ago
parent
commit
130fbaa265
1 changed files with 21 additions and 15 deletions
  1. +21
    -15
      solr_import.sh

+ 21
- 15
solr_import.sh View File



sleep 30 sleep 30


docker run --rm -v "$directory/$location:/$core" --network=host solr:8.11.1 post -c $core /$core
docker run --rm -v "$main_directory/$location:/$core" --network=host solr:8.11.1 post -c $core /$core
} }


Import_recursive() Import_recursive()
{ {
docker run --rm -v "$directory/$subdirectory:/$core" --network=host solr:8.11.1 post -c $core /$core
docker run --rm -v "$main_directory/$subdirectory:/$core" --network=host solr:8.11.1 post -c $core /$core
} }
############################################################ ############################################################
############################################################ ############################################################
############################################################ ############################################################


# set variables # set variables
directory="/Users/ad7588/projects/patent_site_python"
main_directory="/Users/ad7588/projects/patent_site_python"
expanding_directory="data/pop_rtfs/EXPANDING (169)"
active_directory="data/pop_rtfs/ACTIVE (160)"
secret_directory="data/pop_rtfs/SECRET (92)"
leaking_directory="data/pop_rtfs/LEAKING (168)"
working_directory="data/pop_rtfs/WORKING (101)"
resourceful_directory="data/pop_rtfs/RESOURCEFUL (166)"


# error message for no flags # error message for no flags
if (( $# == 0 )); then if (( $# == 0 )); then
exit;; exit;;
e) # index EXPANDING folder e) # index EXPANDING folder
core="expanding" core="expanding"
location="data/pop_rtfs/EXPANDING (169)"
location=$expanding_directory
Import Import
exit;; exit;;
a) # index ACTIVE folder a) # index ACTIVE folder
core="active" core="active"
location="data/pop_rtfs/ACTIVE (160)"
location=$active_directory
Import Import
exit;; exit;;
x) # index SECRET folder x) # index SECRET folder
core="secret" core="secret"
location="data/pop_rtfs/SECRET (92)"
location=$secret_directory
Import Import
exit;; exit;;
p) # index LEAKING folder p) # index LEAKING folder
core="leaking" core="leaking"
location="data/pop_rtfs/LEAKING (168)"
location=$leaking_directory
Import Import
exit;; exit;;
w) # index WORKING folder w) # index WORKING folder
core="working" core="working"
location="data/pop_rtfs/WORKING (101)"
location=$working_directory
Import Import
exit;; exit;;
r) # index RESOURCEFUL folder r) # index RESOURCEFUL folder
core="resourceful" core="resourceful"
location="data/pop_rtfs/RESOURCEFUL (166)"
location=$resourceful_directory
Import Import
exit;; exit;;
t) # index all themes folders t) # index all themes folders
core="expanding" core="expanding"
location="data/pop_rtfs/EXPANDING (169)"
location=$expanding_directory
Import Import
core="active" core="active"
location="data/pop_rtfs/ACTIVE (160)"
location=$active_directory
Import Import
core="secret" core="secret"
location="data/pop_rtfs/SECRET (92)"
location=$secret_directory
Import Import
core="leaking" core="leaking"
location="data/pop_rtfs/LEAKING (168)"
location=$leaking_directory
Import Import
core="working" core="working"
location="data/pop_rtfs/WORKING (101)"
location=$working_directory
Import Import
core="resourceful" core="resourceful"
location="data/pop_rtfs/RESOURCEFUL (166)"
location=$resourceful_directory
Import Import
exit;; exit;;
\?) # Invalid option \?) # Invalid option

Loading…
Cancel
Save