#!/bin/bash

# 替换教务系统业务地址
sed -i "s/_JXCMS_ADDR/$JXCMS_ADDR/g" /etc/nginx/http.d/default.conf
# 替换论坛系统业务地址
sed -i "s/_JXDISCUZ_ADDR/$JXDISCUZ_ADDR/g" /etc/nginx/http.d/default.conf
# 替换视频系统业务地址
sed -i "s/_JXSEA_ADDR/$JXSEA_ADDR/g" /etc/nginx/http.d/default.conf
# 替换禅道系统业务地址
sed -i "s/_JXCHANDAO_ADDR/$JXCHANDAO_ADDR/g" /etc/nginx/http.d/default.conf

# 启动nginx，实时显示访问日志
nginx
tail -f /var/log/nginx/access.log
