weblogic部署指令碼

來源:互聯網
上載者:User

標籤:

#!/bin/bash#date 2016-07-12#writen lxhdir_war=/home/weblogic/wardir_app=/servyouapp/weblogic/user_projects/domains/shyznwgl_domain/appdir_bak=/home/weblogic/backupdir_restart=/servyouapp/weblogic/user_projects/scriptsdeal(){    echo -e "\033[33m-----------------------${i}------------------------------\033[0m"    echo "[INFO] 部署${i}..."    echo "[INFO] 備份${i}..."    [ -f $dir_bak/${i}.03 ]&&rm -f $dir_bak/${i}.03    [ -f $dir_bak/${i}.02 ]&&mv $dir_bak/${i}.02 $dir_bak/${i}.03    [ -f $dir_bak/${i}.01 ]&&mv $dir_bak/${i}.01 $dir_bak/${i}.02    [ -f $dir_app/${i} ]&&mv $dir_app/$i $dir_bak/${i}.01    mv $dir_war/$i $dir_app/    echo "[START...] ${i}重啟中..."        sed -i ‘s/tail/#tail/g‘ $dir_restart/$1    sh $dir_restart/$1    sed -i ‘s/#tail/tail/g‘ $dir_restart/$1    echo ""}echo "檢查是否有war封裝更新..."n1=`ls $dir_war |wc -l`if [ $n1 -eq 0 ];then    echo -e "\033[31m[WRING...] ${dir_war}中無war包!\033[0m"    exit;fiecho "war包識別..."for i in `ls $dir_war`;do    case $i in        dzswj-authentication-platform.war)            deal reshtyrzyz-nw.sh            ;;        dzswj-user-manager-platform.war)            deal reshmhyz-nw.sh            ;;        fcsyy-app-nw-web.war)            deal reshfcsyz-nw.sh            ;;        nsqd-nw-web.war)            deal reshwszyz-nw.sh            ;;        nsqd-nw-ws.war)            deal reshwszyz-nw.sh            ;;        wsjs-app-nw-web.war)            deal reshwsjsyz-nw.sh            ;;        wssb-app-nw-web.war)            deal reshwssbyz-nw.sh            ;;        wsz-nw-web.war)            deal reshxwszyz-nw.sh            ;;        *)            echo -e "\033[31m[WRING...] ${i}包名不匹配,請檢查!\033[0m" >>deploy.tmp            ;;    esacdone[ -f deploy.tmp ]&&cat deploy.tmp[ -f deploy.tmp ]&&rm -f deploy.tmpecho -e "\033[32m部署完成!請查看相應開機記錄。\033[0m"

 

weblogic部署指令碼

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.