summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorSky Swimmer2021-07-28 14:46:19 +0200
committerSky Swimmer2021-07-28 14:46:19 +0200
commit5a7404133d544158438be4ed69786fc04975ce69 (patch)
tree10c390fec03c2b65c628edf01b1ef58e30f7783a
parent9fe79778a70d7b4a4b4556e1592d8f98f952f638 (diff)
downloadaur-5a7404133d544158438be4ed69786fc04975ce69.tar.gz
Fix install script
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD2
-rw-r--r--main.install20
3 files changed, 21 insertions, 3 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ffea70618d5c..a7149e40b7a3 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = connective-index-pages
pkgdesc = Custom Index Pages module for Connective servers
pkgver = 1.0.0
- pkgrel = 1
+ pkgrel = 2
install = main.install
arch = any
groups = connective-server
diff --git a/PKGBUILD b/PKGBUILD
index bfa3cee8a694..2dab0bd16b5d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=connective-index-pages
pkgver=1.0.0
-pkgrel=1
+pkgrel=2
pkgdesc="Custom Index Pages module for Connective servers"
arch=( 'any' )
url=""
diff --git a/main.install b/main.install
index b8b66108cfe6..9691382cf237 100644
--- a/main.install
+++ b/main.install
@@ -12,7 +12,7 @@ post_install() {
mkdir "$serverDir/modules" -p
chown connective:connective "$serverDir/modules" -R
- cp "/usr/lib/customindexpages/CustomIndexPages.jar" "$serverDir/modules/CustomIndexPages.jar" -f
+ ln -sf "/usr/lib/customindexpages/CustomIndexPages.jar" "$serverDir/modules/CustomIndexPages.jar"
chown connective "$serverDir/modules/CustomIndexPages.jar"
if [ -f "$serverDir"/server.ccfg ] && cq org.asf.connective.standalone.main.ConnectiveConfiguration --source-jar /usr/lib/connective-http/ConnectiveStandalone.jar --source-jar /usr/lib/connective-http/libs/RatsMemory.jar "$serverDir"/server.ccfg .context.root &>/dev/null; then
@@ -27,6 +27,24 @@ defaultindexpage "class:org.asf.connective.customindexpages.CustomIndexPageProvi
fi
}
+post_upgrade() {
+ serverDir=/etc/connective-http
+ classPathFolders=( "libs/" )
+ mainType=org.asf.connective.standalone.main.ConnectiveStandalone
+ credtoolLibs=()
+ credtoolTarget=""
+ jvmArguments="-Djava.net.preferIPv4Stack=true"
+
+ if [ -f "/etc/connective-http/config.props" ]; then
+ source "/etc/connective-http/config.props"
+ fi
+
+ mkdir "$serverDir/modules" -p
+ chown connective:connective "$serverDir/modules" -R
+ ln -sf "/usr/lib/customindexpages/CustomIndexPages.jar" "$serverDir/modules/CustomIndexPages.jar"
+ chown connective "$serverDir/modules/CustomIndexPages.jar"
+}
+
post_remove() {
serverDir=/etc/connective-http
classPathFolders=( "libs/" )