summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorEndlessEden2021-09-15 22:37:50 +1000
committerEndlessEden2021-09-15 22:37:50 +1000
commit9a498938946b2f2ba5262915ae6ad92aef95ebdf (patch)
tree449653d8c1ec4710d109fb8d773a1986953a7d91
parentd8fae723e2b97e302bc8520d36673efedf9b3136 (diff)
downloadaur-9a498938946b2f2ba5262915ae6ad92aef95ebdf.tar.gz
Given up on using MD5 for craftycontroller.install until its fixed. cannot find fault.
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD2
-rw-r--r--craftycontroller.install22
3 files changed, 22 insertions, 4 deletions
diff --git a/.SRCINFO b/.SRCINFO
index c533f680c85c..ca8a632a2ccc 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -32,7 +32,7 @@ pkgbase = craftycontroller-git
source = craftycontroller.service
source = start.sh
md5sums = SKIP
- md5sums = f18b2c7e59c71dc94b4260c8bd2a2807
+ md5sums = SKIP
md5sums = 2e7d24f5d2982fc6f7ac224378cf2f02
md5sums = 0b6cd32e5c31ed3bb576f5ad652c0db6
diff --git a/PKGBUILD b/PKGBUILD
index 475dd566e45e..bf6eb38d1b6d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -17,7 +17,7 @@ source=("$_pkgname"::"git+https://gitlab.com/crafty-controller/crafty-web.git"
"$_pkgname.service"
"start.sh")
md5sums=('SKIP'
-'f18b2c7e59c71dc94b4260c8bd2a2807'
+'SKIP'
'2e7d24f5d2982fc6f7ac224378cf2f02'
'0b6cd32e5c31ed3bb576f5ad652c0db6')
diff --git a/craftycontroller.install b/craftycontroller.install
index 8dccb517508d..606b44111e36 100644
--- a/craftycontroller.install
+++ b/craftycontroller.install
@@ -1,24 +1,42 @@
post_install() {
echo "Creating user for Crafty Controller..."
+
useradd -M -r -s /bin/bash -b "/opt/craftycontroller" crafty
+
echo "Setting Permissions..."
+
chown -R crafty:crafty "/opt/craftycontroller"
+
echo "Creating the Python Virtual Enviorment..."
+
cd "/opt/craftycontroller"
+
python3 -m venv craftycontroller
+
echo "Warning: About to run first-time Launch!"
- echo
+
+ echo " "
+
echo "Prepare for prompt, for first-time configuration!"
+
echo "Crafty Controller/Crafty Web, is located at: /opt/craftycontroller"
- echo
+
+ echo " "
+
echo "Starting..."
+
echo "3..."
+
echo "2..
+
echo "1."
+
sudo -u crafty /usr/bin/bash -c /opt/craftycontroller/start.sh && export success=1 & exit 0
+
if [ ! -z "$success" ]; then
export success="0"
fi
+
if [ "$success" == "0" ]; then
echo "Initialisation failed, Please run /opt/craftycontroller/start.sh as crafty user."
fi