forked from alminium/alminium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathuninstall
69 lines (50 loc) · 1.18 KB
/
uninstall
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#!/bin/bash
GEM=`which gem2.0`
if [ "$GEM" = "" ]
then
GEM=gem
fi
echo "ALMiniumをアンインストールします。"
echo ""
echo -n "データベース(全てのRedmineの情報)とリポジトリを削除しますか?(y/N)"
read YN
if [ "$YN" = "y" ]
then
mysql alminium -e "drop database alminium"
rm -fr /opt/alminium /var/opt/alminium
fi
echo ""
echo -n "Apacheの設定を削除しますか?(y/N)"
read YN
if [ "$YN" = "y" ]
then
rm -fr /etc/apache2/sites-available/vcs
rm -fr /etc/apache2/sites-available/redmine
rm -fr /etc/apache2/sites-enabled/vcs
rm -fr /etc/apache2/sites-enabled/redmine
rm -fr /etc/httpd/conf.d/redmine.conf
rm -fr /etc/httpd/conf.d/vcs.conf
rm -fr /etc/httpd/conf.d/jenkins.conf
fi
echo ""
echo -n "Passengerを削除しますか?(y/N)"
read YN
if [ "$YN" = "y" ]
then
echo "3" | $GEM uninstall passenger
fi
echo ""
echo -n "Jenkisとその設定を削除しますか?(y/N)"
read YN
if [ "$YN" = "y" ]
then
yum -y remove jenkins
rm -fr /var/lib/jenkins
fi
echo ""
echo -n "キャッシュされたファイルを削除しますか?(y/N)"
read YN
if [ "$YN" = "y" ]
then
rm -fr cache *.installed
fi