install-eg.sh: Ang client: use "ng build --prod" and remove existing files before...
authorJeff Davis <jdavis@sitka.bclibraries.ca>
Tue, 8 Oct 2019 17:31:47 +0000 (10:31 -0700)
committerJeff Davis <jdavis@sitka.bclibraries.ca>
Tue, 8 Oct 2019 17:31:47 +0000 (10:31 -0700)
deployment/install-eg.sh

index 55c7995..e2c5fa7 100755 (executable)
@@ -100,7 +100,7 @@ if [[ ! -n "$TARBALL" && ! -n "$SKIPWEBCLIENT" ]] ; then
     cd ${BUILDDIR}/Open-ILS/src/eg2/
     sed -i "s|'/openils/lib/javascript|'${INSTALLDIR}/lib/javascript|g" ${BUILDDIR}/Open-ILS/src/eg2/karma.conf.js
     suwrap "npm install" ${INSTALL_USER}
-    suwrap "ng build && npm run test" ${INSTALL_USER} || { echo 'Could not install files for Angular staff client' ; exit 1; }
+    suwrap "ng build --prod && npm run test" ${INSTALL_USER} || { echo 'Could not install files for Angular staff client' ; exit 1; }
   fi
 fi
 
@@ -111,6 +111,7 @@ suwrap "cd ${BUILDDIR} && make" ${INSTALL_USER}
 [ ! -n "$TARBALL" ] && suwrap "cd ${BUILDDIR}/build/i18n && make LOCALE=fr-CA install && make LOCALE=en-CA install" ${INSTALL_USER}
  
 # as root
+rm -rf ${INSTALLDIR}/var/web/eg2/en-US
 cd ${BUILDDIR} && make install
 mv ${INSTALLDIR}/var/web/reports/fm_IDL.xml ${INSTALLDIR}/var/web/reports/fm_IDL.xml.orig && cp ${INSTALLDIR}/conf/fm_IDL.xml ${INSTALLDIR}/var/web/reports/