Browse Source

************* wx **********************************
添加数据中心说明

张维新 4 years ago
parent
commit
cfd71ecac7

BIN
docs/setup/centos/server/img/tomcat_setenv_001.png


BIN
docs/setup/centos/server/img/tomcat_setenv_002.png


+ 8 - 1
docs/setup/centos/server/postgresql.md

@@ -37,9 +37,16 @@
 首先,切换到postgres用户。然后执行修改用户密码SQL语句。其中“postgres”为要修改密码的用户,“123456”为用户的密码。
 ```
 [root@localhost ~] su - postgres
-bash-4.2$ psql -c "alter user postgres with password '123456'"
+-bash-4.2$ psql
+postgres=# alter user postgres with password '123456';
+postgres-# \q
+
+* 注意设置密码后面的分号不可以忽略
 ```
 
+
+
+
 ### 修改配置文件
 
 打开并编辑文件“/var/lib/pgsql/12/data/postgresql.conf”。将“#listen_addresses = 'localhost'”改为“listen_addresses = '*'”

+ 5 - 2
docs/setup/centos/server/python.md

@@ -4,7 +4,7 @@
 
 ## 安装
 
-CentOS7默认软件源中没有Python3,要安装Python3需首先安装epel软件源。
+CentOS7默认软件源中没有Python3,要安装Python3需首先安装epel软件源,非root账户下请使用 sudo yum install epel-release 
 ```
 [root@localhost ~] yum install epel-release
 ```
@@ -24,4 +24,7 @@ CentOS7默认软件源中没有Python3,要安装Python3需首先安装epel软
 [root@localhost ~] pip3 install shapely
 [root@localhost ~] pip3 install networkx
 [root@localhost ~] pip3 install jieba
-```
+```
+### 安装过程遇到的问题 
+
+

+ 14 - 3
docs/setup/centos/server/tomcat.md

@@ -5,16 +5,16 @@
 
 下载地址:[https://tomcat.apache.org/download-90.cgi](https://tomcat.apache.org/download-90.cgi)
 
-下载地址:[http://mirrors.tuna.tsinghua.edu.cn/apache/tomcat/tomcat-9/v9.0.27/bin/apache-tomcat-9.0.27.tar.gz](http://mirrors.tuna.tsinghua.edu.cn/apache/tomcat/tomcat-9/v9.0.27/bin/apache-tomcat-9.0.27.tar.gz)
+下载地址:[https://mirror.bit.edu.cn/apache/tomcat/tomcat-9/v9.0.34/bin/apache-tomcat-9.0.34.tar.gz](http://mirrors.tuna.tsinghua.edu.cn/apache/tomcat/tomcat-9/v9.0.27/bin/apache-tomcat-9.0.27.tar.gz)
 
 使用 wget 命令下载 Tomcat9 。
 ```
-[root@localhost ~] wget http://mirrors.tuna.tsinghua.edu.cn/apache/tomcat/tomcat-9/v9.0.27/bin/apache-tomcat-9.0.27.tar.gz
+[root@localhost ~] wget https://mirror.bit.edu.cn/apache/tomcat/tomcat-9/v9.0.34/bin/apache-tomcat-9.0.34.tar.gz
 ```
 
 ## 安装
 ```
-[root@localhost ~] tar xvf apache-tomcat-9.0.27.tar.gz -C /opt
+[root@localhost ~] tar xvf apache-tomcat-9.0.34.tar.gz -C /opt
 ```
 
 ## 配置
@@ -93,4 +93,15 @@ WantedBy=multi-user.target
 [root@localhost ~] systemctl disable tomcat
 ```
 
+### 自定义读取yml文件配置
+打开/opt/tomcat9/bin 新建文件名为setenv.sh
+
+![自定义读取yml文件配置](./img/tomcat_setenv_001.png)
+
+文件内容 active=prod 等号后面是读取的  后置为prod 的yml文件
+```
+export CATALINA_OPTS="$CATALINA_OPTS -Dspring.profiles.active=prod"
+```
+![自定义读取yml文件配置](./img/tomcat_setenv_002.png)
+
 ## 常见问题处理