-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathweb_script.sh
More file actions
46 lines (39 loc) · 1.4 KB
/
web_script.sh
File metadata and controls
46 lines (39 loc) · 1.4 KB
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
#!/bin/bash
#Installing Dependencies
echo "#####################################################################"
echo "Installing packages"
echo "#####################################################################"
sudo yum install wget unzip httpd -y > /dev/null
echo
# Start & Enable Service
echo "#####################################################################"
echo "Start & Enable HTTPS Service"
echo "#####################################################################"
sudo systemctl start httpd
sudo systemctl enable httpd
echo
# Creating Temp directory
echo "#####################################################################"
echo "Starting Artifact Deployment"
echo "#####################################################################"
mkdir -p /tmp/webfiles
cd /tmp/webfiles
echo
wget https://www.tooplate.com/zip-templates/2098_health.zip
unzip 2098_health.zip
sudo cp -r 2098_health/* /var/www/html
echo
# Bounce Service
echo "#####################################################################"
echo "Restarting HTTPD Service"
echo "#####################################################################"
systemctl restart httpd
echo
# Clean up
echo "#####################################################################"
echo "Removing temp files"
echo "#####################################################################"
rm -rf /tmp/webfiles
echo
sudo systemctl status httpd
ls /var/www/html