replace.sh 1.0 KB

1234567891011121314151617181920212223242526272829
  1. #!/bin/bash
  2. help(){
  3. echo "eg: $0 [dir]"
  4. echo ""
  5. exit 1
  6. }
  7. if [ ! -n "$1" ] ; then
  8. help
  9. fi
  10. c_home=$(cd `dirname $0`; pwd)
  11. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/mysql-boot.sh
  12. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/mysql.sh
  13. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/mssql-boot.sh
  14. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/mssql.sh
  15. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/oracle-boot.sh
  16. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/oracle.sh
  17. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/postgre-boot.sh
  18. sed -i 's/192.168.3.230 192.168.3.230/192.168.3.230 192.168.3.206/g' ${c_home}/$1/postgre.sh
  19. sed -i 's/192.168.3.230/192.168.3.210/g' ${c_home}/$1/bin/env/platform.docker.env
  20. cp -f ${c_home}/license/* ${c_home}/$1/bin/license/