Skip to content
Snippets Groups Projects
Commit be09c541 authored by Alexander König's avatar Alexander König
Browse files

Merge branch 'master' of gitlab.inf.unibz.it:commul/docker/clarin-dspace

parents 26abf51d 4d4830c1
No related branches found
No related tags found
No related merge requests found
#!/bin/sh
#!/bin/bash
# replace environment variables in config files
perl -pi -e 's/\$\{DSPACE_USER\}/$ENV{DSPACE_USER}/; s/\$\{DSPACE_PASSWORD\}/$ENV{DSPACE_PASSWORD}/; s/\$\{MAIL_USER\}/$ENV{MAIL_USER}/; s/\$\{MAIL_PASSWORD\}/$ENV{MAIL_PASSWORD}/; s/\$\{DSPACE_DBNAME\}/$ENV{DSPACE_DBNAME}/; s/\$\{DSPACE_UTILSDBNAME\}/$ENV{DSPACE_UTILSDBNAME}/;' /opt/repository/sources/dspace/local.properties
......@@ -16,9 +16,31 @@ perl -pi -e 's/\$\{HANDLE_USER\}/$ENV{HANDLE_USER}/; s/\$\{HANDLE_PASSWORD\}/$EN
/opt/tomcat8/bin/startup.sh
cd /opt/repository/workspace/scripts
make init_statistics
make update_discovery
make update_oai
/opt/lindat-dspace/installation/bin/dspace generate-sitemaps
# https://ubuntuforums.org/showthread.php?t=979694
# Start process in the background and send its output to file descriptor 3
exec 3< <(while (true); do
make update_oai
make update_statistics
make update_sitemap
make lift_embargos
make update_openaire_cache
make update_discovery
echo "INIT DONE."
sleep 86400
done)
# Read the output of the process line by line until one line contains Ready
while read line; do
case "$line" in
"INIT DONE.")
break
;;
esac
done <&3
# Close the file descriptor
exec <&3 3<&-
/opt/tomcat8/bin/shutdown.sh -force
# start tomcat
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment