Last change
on this file since 235 was
217,
checked in by rock, 14 years ago
|
Add: KVM support (bridge to eth for KVM env)
|
-
Property svn:executable set to
*
|
File size:
1.1 KB
|
Rev | Line | |
---|
[162] | 1 | #!/bin/bash |
---|
| 2 | # Program: |
---|
| 3 | # Install DRBL virt module |
---|
| 4 | # Author: |
---|
| 5 | # Jazz, Rock {jazz, rock}@nchc.org.tw |
---|
| 6 | # Version: |
---|
| 7 | # 1.0 |
---|
| 8 | # History: |
---|
| 9 | # 2010/08/03 Rock First release (1.0) |
---|
| 10 | |
---|
[202] | 11 | |
---|
| 12 | # [Path] |
---|
[162] | 13 | Work_Home="/opt/drbl-virt" |
---|
| 14 | Work_Path="/opt/drbl-virt/sbin" |
---|
[171] | 15 | Now_Path="$(dirname $0)" |
---|
[202] | 16 | PATH=${PATH}:$Work_Path:${Now_Path}/sbin |
---|
[162] | 17 | |
---|
[202] | 18 | # Source] |
---|
[171] | 19 | source $Now_Path/sbin/functions_drbl_virt |
---|
[162] | 20 | |
---|
| 21 | # [Main] |
---|
| 22 | check_root |
---|
| 23 | |
---|
[188] | 24 | jude="no" |
---|
| 25 | if [ -e $Work_Home ]; then |
---|
[217] | 26 | echo -e "\nThis system already has drbl-virt." |
---|
[188] | 27 | read -p "Do you want to install, again (yes/no): " jude |
---|
| 28 | |
---|
| 29 | if [ $jude == "yes" ]; then |
---|
| 30 | rm -fr $Work_Home |
---|
| 31 | else |
---|
| 32 | echo "Exit" |
---|
| 33 | exit |
---|
| 34 | fi |
---|
| 35 | fi |
---|
| 36 | |
---|
[202] | 37 | |
---|
| 38 | # = 1. Create /opt/drbl-virt and copy file = |
---|
[162] | 39 | mkdir -p $Work_Home |
---|
[185] | 40 | mkdir $Work_Home/etc |
---|
| 41 | mkdir $Work_Home/.tmp |
---|
[171] | 42 | cp -fr $Now_Path/sbin $Work_Home/ |
---|
| 43 | cp -fr $Now_Path/conf $Work_Home/ |
---|
| 44 | cp -fr $Now_Path/uninstall.sh $Work_Home/ |
---|
[188] | 45 | |
---|
[202] | 46 | # = 2. Move war = |
---|
[207] | 47 | #mv drbl-virt.war $Work_Home/ |
---|
[202] | 48 | |
---|
| 49 | # = 4. Install completion = |
---|
| 50 | echo "" |
---|
| 51 | echo "[drbl-virt install completion]" |
---|
| 52 | echo "Please go to /opt/drbl-virt/ to check !!!" |
---|
Note: See
TracBrowser
for help on using the repository browser.