aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbaigk <baiguoku@huawei.com>2015-09-10 04:01:39 -0400
committerbaigk <baiguoku@huawei.com>2015-09-10 04:01:39 -0400
commitbc66375c3e7b48d78f71ddf4730b97dcb3987a74 (patch)
treea503db9c53b833fac11537bb9664478804e2c345
parent5261f2cce8d70195a978232f804b478eab6cfd72 (diff)
adjust iso and ppa path in compass.iso
JIRA: COMPASS-40 Change-Id: If10ec4be9613303584d5ca8bfdfe9b4790ac1d46 Signed-off-by: baigk <baiguoku@huawei.com>
-rwxr-xr-xbuild.sh10
-rw-r--r--deploy/compass_vm.sh2
-rw-r--r--util/ks.cfg3
3 files changed, 9 insertions, 6 deletions
diff --git a/build.sh b/build.sh
index dd4e7a18..c018a1d5 100755
--- a/build.sh
+++ b/build.sh
@@ -91,15 +91,17 @@ function copy_file()
new=$1
# main process
- sudo mkdir -p $new/repos $new/compass $new/bootstrap $new/pip $new/guestimg $new/app_packages $new/ansible
+ sudo mkdir -p $new/compass $new/bootstrap $new/pip $new/guestimg $new/app_packages $new/ansible
+ sudo mkdir -p $new/repos/cobbler/{ubuntu,centos}/{iso,ppa}
sudo cp -rf $SCRIPT_DIR/util/ks.cfg $new/isolinux/ks.cfg
sudo rm -rf $new/.rr_moved
- for i in $TRUSTY_JUNO_PPA $UBUNTU_ISO $CENTOS_ISO $CENTOS7_JUNO_PPA; do
- sudo cp $CACHE_DIR/`basename $i` $new/repos/ -rf
- done
+ sudo cp $CACHE_DIR/`basename $UBUNTU_ISO` $new/repos/cobbler/ubuntu/iso/ -rf
+ sudo cp $CACHE_DIR/`basename $TRUSTY_JUNO_PPA` $new/repos/cobbler/ubuntu/ppa/ -rf
+ sudo cp $CACHE_DIR/`basename $CENTOS_ISO` $new/repos/cobbler/centos/iso/ -rf
+ sudo cp $CACHE_DIR/`basename $CENTOS7_JUNO_PPA` $new/repos/cobbler/centos/ppa/ -rf
sudo cp $CACHE_DIR/`basename $LOADERS` $new/ -rf || exit 1
sudo cp $CACHE_DIR/`basename $CIRROS` $new/guestimg/ -rf || exit 1
diff --git a/deploy/compass_vm.sh b/deploy/compass_vm.sh
index 4c40c1e4..067918da 100644
--- a/deploy/compass_vm.sh
+++ b/deploy/compass_vm.sh
@@ -30,7 +30,7 @@ function install_compass_core() {
function wait_ok() {
log_info "wait_compass_ok enter"
retry=0
- until timeout 1s ssh $ssh_args root@$MGMT_IP "exit" 2>/dev/null
+ until timeout 1s ssh $ssh_args root@$MGMT_IP "exit" >/dev/null 2>&1
do
log_progress "os install time used: $((retry*100/$1))%"
sleep 1
diff --git a/util/ks.cfg b/util/ks.cfg
index e3008819..7d70e6f2 100644
--- a/util/ks.cfg
+++ b/util/ks.cfg
@@ -220,11 +220,12 @@ rm -rf ${repodir}/source/bootstrap/ \
${repodir}/source/pip/ \
${repodir}/source/repos
-mkdir -p /root/.ssh
+mkdir -p /root/.ssh /var/www /opt/cobbler
chmod 700 /root/.ssh
cat ${SOURCE}/bootstrap/boot.rsa.pub >> /root/.ssh/authorized_keys
cp -rf ${SOURCE}/compass/* /opt
+cp -rf ${SOURCE}/repos/cobbler/* /opt/cobbler/
cp -rf ${SOURCE}/ansible/* /opt
cp -rf ${SOURCE}/repos/* /opt
cp -rf ${SOURCE}/loaders.tar.gz /opt