-
Notifications
You must be signed in to change notification settings - Fork 3
/
foiflowstart_linux.sh
executable file
·44 lines (33 loc) · 1.19 KB
/
foiflowstart_linux.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/sh
setlocal enableextensions enabledelayedexpansion
REPO_URL=https://github.com/AOT-Technologies/forms-flow-ai.git
REPO_BRANCH=v4.0.5-alpha
START_REDIS=N
FFA_APPS_ROOT=apps/forms-flow-ai
BPM_DIRECTORY=apps/forms-flow-ai/forms-flow-bpm
FFA_REPO_DIRECTORY=${FFA_APPS_ROOT}/${REPO_BRANCH}
FFA_WEB_DIRECTORY="${FFA_APPS_ROOT}/forms-flow-ai-web"
echo 'hello world'
echo $REPO_URL
if [ -d "${FFA_REPO_DIRECTORY}" ]
then
echo "Folder already exists"
else
echo "BPM Folder NOT exists"
sudo mkdir -p $FFA_REPO_DIRECTORY
chmod 777 -R $FFA_REPO_DIRECTORY
echo "created folder path ${FFA_REPO_DIRECTORY}"
echo "Clone formsflow.ai"
git clone -b $REPO_BRANCH $REPO_URL $FFA_REPO_DIRECTORY
fi
chmod 777 -R $FFA_REPO_DIRECTORY
if [ -d "${FFA_REPO_DIRECTORY}/forms-flow-bpm" ]
then
echo "Removing addition files from ${FFA_DIRECTORY}/forms-flow-bpm/src/main/resources/processes"
rm -r "${FFA_REPO_DIRECTORY}/forms-flow-bpm/src/main/resources/processes"
cp -uaT "${FFA_REPO_DIRECTORY}/forms-flow-bpm/src" "${BPM_DIRECTORY}/src"
fi
if [ -d "${FFA_REPO_DIRECTORY}/forms-flow-web" ]
then
cp -uaT "${FFA_REPO_DIRECTORY}/forms-flow-web" $FFA_WEB_DIRECTORY
fi