-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.sh
executable file
·48 lines (39 loc) · 1.13 KB
/
install.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
44
45
46
47
48
#!/bin/bash
##################
# Install WORM
##################
dir=$(pwd)
# Check we have PHP installed
if ! command -v php &> /dev/null
then
echo "PHP could not found on this machine, and is a requirement
for WORM. Terminating install."
exit
fi
# Check we have AWS cli installed
if ! command -v aws &> /dev/null
then
echo "AWS cli could not found on this machine, and is a requirement
for WORM. Terminating install."
exit
fi
# Check we have kubectl installed
if ! command -v kubectl &> /dev/null
then
echo "kubectl could not found on this machine, and is a requirement
for WORM. Terminating install."
exit
fi
# Check we have kubectl installed
if ! command -v cloud-platform &> /dev/null
then
echo "cloud-platform could not found on this machine, and is a requirement
for WORM. Run brew install ministryofjustice/cloud-platform-tap/cloud-platform-cli
Terminating install."
exit
fi
# Build binary of latest worm
php worm app:build --build-version=0.7.0 --no-interaction
# System link to add build to local $PATH
sudo ln -s $dir/builds/worm /usr/local/bin/worm
echo "WORM installed successfully"