Skip to content

Commit 571a0b2

Browse files
TranscodeGroupDeveloperth-ciroot
authored
chroe: 更新文档 & sql初始化数据 & 修复nginx中localhost的路由 等 (#3)
* wip: 更新readme * fix: 将default.conf复写成空文件, 防止影响localhost域名的路由 * chore: remote version field * wip:初始化用户表时增加平台管理员账号 --------- Co-authored-by: th-ci <[email protected]> Co-authored-by: root <[email protected]>
1 parent c7413a0 commit 571a0b2

File tree

5 files changed

+68
-11
lines changed

5 files changed

+68
-11
lines changed

README.md

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,24 +7,33 @@ docker配置文件仓库
77
### 1. 初始化
88

99
```sh
10-
git clone https://github.com/TranscodeGroup/docker.git /home/docker
11-
mkdir /home/docker-compose
10+
mkdir -p /home/docker-compose
1211
mkdir /data
12+
git clone https://github.com/TranscodeGroup/docker.git /home/docker
1313
```
1414

15-
### 2. 配置compse.yaml
15+
### 2. 配置`compse.yaml`
1616

1717
创建`/home/docker-compose/compose.yaml`文件, 参考如下示例:
1818

19-
- [RTP存储 - video.storage.stack.yaml](./video.storage.stack.yaml)
20-
- [RTP视频 - video.stream.stack.yaml](./video.stream.stack.yaml)
19+
- [video.storage.stack.yaml](./video.storage.stack.yaml): RTP存储
20+
- [video.stream.stack.yaml](./video.stream.stack.yaml): RTP视频
21+
- [single.stack.yaml](./single.stack.yaml): V2单机部署
2122

22-
### 3. 配置.env
23+
### 3. 配置`.env`
2324

2425
创建`/home/docker-compose/.env`文件, 参考[.env.default](./.env.default)复写需要改写的配置项.
2526

26-
使用在`/home/docker-compose`中执行如下命令, 验证所有使用到的必填的值, 是否已经设置:
27+
`/home/docker-compose`中执行如下命令, 验证所有使用到的必填的值, 是否已经设置:
2728

2829
```sh
2930
docker compose config
3031
```
32+
33+
### 4. 启动
34+
35+
`/home/docker-compose`中执行如下命令, 启动docker:
36+
37+
```sh
38+
docker compose up
39+
```

maintain/compose.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
version: '3'
21
services:
32
maintain:
43
image: transcodegroup/maintain-server

mysql8/initdb/01-create-db-maintain-20250429.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3894,7 +3894,7 @@ CREATE TABLE `user_info` (
38943894
-- Records of user_info
38953895
-- ----------------------------
38963896
INSERT INTO `user_info` VALUES (15865, 'dca0f9e348384d23958e151bb4adb98f', '系统管理员', 'sysadmin', '{bcrypt-md5}$2a$10$dsfVEzh5NlfrgkcLFbrPLOuSsm5zJMJJwYqlQfTSWs3qKzwhQx5Ku', '/minio/maintain/avatar/202504/3e9b5f914ff105ea2d32c4a4c53b10121a16aac4.png', NULL, NULL, '+08:00', NULL, 0, 0, 100, 0, '', '系统账号', '2025-04-29 09:27:50', NULL, NULL, '2025-04-29 03:46:24', 0, NULL, '', 0, '2025-04-29 03:46:24', '2025-04-29 09:28:57');
3897-
3897+
INSERT INTO `user_info` VALUES (15866, '25d19d8c917747ea', 'tgadmin', '组织管理员', '{bcrypt-md5}$2a$10$x7PPR5QH/2yooQmv4szk5O4.l1AujbzMbosaO4SaYL9UxXTsOKKey', '/minio/maintain/avatar/202504/db1c192ad620acdff541de0125ae887bf2366a2b.png', NULL, NULL, '+08:00', NULL, 0, 0, 1, 0, '', NULL, '2025-04-30 08:04:22', NULL, NULL, '2025-04-30 07:35:32', 0, 110, '', 0, '2025-04-30 07:35:32', '2025-04-30 08:22:00');
38983898
-- ----------------------------
38993899
-- Table structure for user_issue
39003900
-- ----------------------------

nginx/compose.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,10 @@ services:
1414
- "/data/nginx/html:/usr/share/nginx/html"
1515
- "/data/nginx/logs:/var/log/nginx"
1616
configs:
17-
- source: nginx.conf
17+
- source: nginx-nginx.conf
1818
target: /etc/nginx/nginx.conf
19+
- source: nginx-default.conf
20+
target: /etc/nginx/conf.d/default.conf
1921

2022
secrets:
2123
ssl-certificate:
@@ -24,5 +26,7 @@ secrets:
2426
file: ${SSL_CERTIFICATE:?required}.key
2527

2628
configs:
27-
nginx.conf:
29+
nginx-nginx.conf:
2830
file: ./conf/nginx.conf
31+
nginx-default.conf:
32+
file: ./conf/default.conf

nginx/conf/default.conf

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# 默认配置会影响通过localhost域名访问bus/track的路由, 故清空它的内容
2+
# server {
3+
# listen 80;
4+
# listen [::]:80;
5+
# server_name localhost;
6+
7+
# #access_log /var/log/nginx/host.access.log main;
8+
9+
# location / {
10+
# root /usr/share/nginx/html;
11+
# index index.html index.htm;
12+
# }
13+
14+
# #error_page 404 /404.html;
15+
16+
# # redirect server error pages to the static page /50x.html
17+
# #
18+
# error_page 500 502 503 504 /50x.html;
19+
# location = /50x.html {
20+
# root /usr/share/nginx/html;
21+
# }
22+
23+
# # proxy the PHP scripts to Apache listening on 127.0.0.1:80
24+
# #
25+
# #location ~ \.php$ {
26+
# # proxy_pass http://127.0.0.1;
27+
# #}
28+
29+
# # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
30+
# #
31+
# #location ~ \.php$ {
32+
# # root html;
33+
# # fastcgi_pass 127.0.0.1:9000;
34+
# # fastcgi_index index.php;
35+
# # fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
36+
# # include fastcgi_params;
37+
# #}
38+
39+
# # deny access to .htaccess files, if Apache's document root
40+
# # concurs with nginx's one
41+
# #
42+
# #location ~ /\.ht {
43+
# # deny all;
44+
# #}
45+
# }

0 commit comments

Comments
 (0)