zoukankan      html  css  js  c++  java
  • env.sh

    #!/bin/sh
    #docker exec -i t nginx /usr/share/app/nginx/vip/webapp/evn.sh test
    testUrl='http://192.168.1.100:3000'
    trueUrl='https://vip.menusifu.com:23080'
    if [ "$1" = "test" ]
    then
    echo "$trueUrl"

    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/nginx/vip/webapp/super/js/app.js
    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/nginx/vip/webapp/super/js/app.js
    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/nginx/vip/webapp/index.html
    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/nginx/vip/webapp/index.html

    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/nginx/vip/webapp/admin/index.html
    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/nginx/vip/webapp/admin/index.html

    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/node/vips/routes/admins.js
    sed -i "s/$trueUrl/$testUrl/g" /usr/share/app/node/vips/routes/admins.js

    else
    echo "$testUrl"
    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/nginx/vip/webapp/super/js/app.js
    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/nginx/vip/webapp/super/js/app.js
    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/nginx/vip/webapp/index.html
    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/nginx/vip/webapp/index.html

    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/nginx/vip/webapp/admin/index.html
    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/nginx/vip/webapp/admin/index.html

    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/node/vips/routes/admins.js
    sed -i "s/$testUrl/$trueUrl/g" /usr/share/app/node/vips/routes/admins.js

    fi
    chmod g+w /usr/share/app/nginx/vip/webapp/super/js/app.js
    chmod g+w /usr/share/app/node/vips/routes/admins.js
    chmod g+w /usr/share/app/nginx/vip/webapp/index.html
    chmod g+w /usr/share/app/nginx/vip/webapp/admin/index.html

  • 相关阅读:
    什么是IOC
    spring的作用
    什么是spring框架?
    72
    71
    70
    69
    68
    67
    66
  • 原文地址:https://www.cnblogs.com/jayruan/p/5778480.html
Copyright © 2011-2022 走看看