签入版本
This commit is contained in:
@@ -97,7 +97,7 @@ mysql -u root -p -e "SELECT user, host FROM mysql.user;"
|
||||
# ON `数据库`.* → 指定数据库的所有表
|
||||
# TO 'root'@'%' → 允许从任意主机连接的 root 用户
|
||||
# IDENTIFIED BY → 设置密码
|
||||
mysql -u root -proot -e "GRANT ALL ON \`rxthinkcmf.thinkphp6.elevue\`.* TO 'root'@'%' IDENTIFIED BY 'root';"
|
||||
mysql -u root -proot -e "GRANT ALL ON \`rxthinkcmf.thinkphp6.antdvue\`.* TO 'root'@'%' IDENTIFIED BY 'root';"
|
||||
mysql -u root -p -e "FLUSH PRIVILEGES;" # 刷新权限使配置生效
|
||||
```
|
||||
|
||||
@@ -112,7 +112,7 @@ sudo systemctl status postgresql
|
||||
# -----------------------------------------------------------------------------
|
||||
# 测试连接(-U 指定用户,-d 指定数据库,-c 执行 SQL)
|
||||
# -----------------------------------------------------------------------------
|
||||
psql -U postgres -d rxthinkcmf.thinkphp6.elevue -c "SELECT 1;"
|
||||
psql -U postgres -d rxthinkcmf.thinkphp6.antdvue -c "SELECT 1;"
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# 检查客户端认证配置(pg_hba.conf 控制哪些 IP 可以连接)
|
||||
@@ -169,14 +169,14 @@ php -m | grep pdo_sqlsrv # 查找 pdo_sqlsrv 扩展
|
||||
# -----------------------------------------------------------------------------
|
||||
|
||||
# MySQL:通过 mysql 命令导入 SQL 文件
|
||||
mysql -u root -proot rxthinkcmf.thinkphp6.elevue < document/mysql/rxthinkcmf.thinkphp6.elevue.sql
|
||||
mysql -u root -proot rxthinkcmf.thinkphp6.antdvue < document/mysql/rxthinkcmf.thinkphp6.antdvue.sql
|
||||
|
||||
# PostgreSQL:通过 psql 命令导入 SQL 文件
|
||||
# -U 指定用户,-d 指定数据库,-f 指定 SQL 文件
|
||||
psql -U postgres -d rxthinkcmf.thinkphp6.elevue -f document/postgresql/rxthinkcmf.thinkphp6.elevue.sql
|
||||
psql -U postgres -d rxthinkcmf.thinkphp6.antdvue -f document/postgresql/rxthinkcmf.thinkphp6.antdvue.sql
|
||||
|
||||
# SQLite:通过 sqlite3 命令导入 SQL 文件
|
||||
sqlite3 /www/api/runtime/database.sqlite < document/sqlite/rxthinkcmf.thinkphp6.elevue.sql
|
||||
sqlite3 /www/api/runtime/database.sqlite < document/sqlite/rxthinkcmf.thinkphp6.antdvue.sql
|
||||
```
|
||||
|
||||
## PHP 问题
|
||||
@@ -268,13 +268,13 @@ grep JWT.SECRET .env
|
||||
# 检查用户角色分配(用户是否分配了角色)
|
||||
# -----------------------------------------------------------------------------
|
||||
# think_user_role 表存储用户与角色的关联关系
|
||||
mysql -u root -proot rxthinkcmf.thinkphp6.elevue -e "SELECT * FROM think_user_role WHERE user_id=1;"
|
||||
mysql -u root -proot rxthinkcmf.thinkphp6.antdvue -e "SELECT * FROM think_user_role WHERE user_id=1;"
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# 检查角色权限(角色是否分配了菜单权限)
|
||||
# -----------------------------------------------------------------------------
|
||||
# think_role_menu 表存储角色与菜单的关联关系
|
||||
mysql -u root -proot rxthinkcmf.thinkphp6.elevue -e "SELECT * FROM think_role_menu WHERE role_id=1;"
|
||||
mysql -u root -proot rxthinkcmf.thinkphp6.antdvue -e "SELECT * FROM think_role_menu WHERE role_id=1;"
|
||||
```
|
||||
|
||||
### 文件上传失败
|
||||
|
||||
Reference in New Issue
Block a user