Skip to content

Commit

Permalink
chore:10月30日
Browse files Browse the repository at this point in the history
  • Loading branch information
aehyok committed Oct 30, 2023
1 parent 56ab99a commit d704a29
Show file tree
Hide file tree
Showing 2 changed files with 72 additions and 1 deletion.
18 changes: 18 additions & 0 deletions docs/daily/2023-10.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,21 @@
## 10月30日
-linux ls 命令
```
// t 根据修改时间排列
// head -n 只列出10条记录
ls -lit | head -n 10
```
- redis分布式锁
- https://juejin.cn/post/7279346413915668535
- 重复订单的问题 https://juejin.cn/post/7273024681631776829
- redis分布式缓存 https://juejin.cn/post/7274146202496614458
- redis集群搭建 https://juejin.cn/post/7293831013318819892
- 得物redis设计与实现 https://juejin.cn/post/7293778973321936908
- redis队列 https://juejin.cn/post/7149483006686822430
- seq日志
- https://github.com/datalust?q=seq&type=all&language=&sort=
- https://hub.docker.com/r/datalust/seq
- https://github.com/serilog/serilog
## 10月26日
- 导出整个数据库结构和数据的命令
- mysqldump -hxxx.xxx.xxx.xxx -P4006 -uroot -pxxxxxxxx dvsv3>/usr/local/sunlight/sql/dvsv3.sql;
Expand Down
55 changes: 54 additions & 1 deletion docs/javascript/2023-10-26-培训.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,4 +94,57 @@ kill id
SHOW OPEN TABLES where In_use > 0;
````
````
##seq日志
```
https://github.com/datalust?q=seq&type=all&language=&sort=
https://hub.docker.com/r/datalust/seq
https://github.com/serilog/serilog
```
## docker seq日志
```
// 安装docker
zypper in docker

docker -v

docker pull datalust/seq

// 设置seq密码
SeqPwd=$(echo 'sunlight2023' | docker run --rm -i datalust/seq config hash)

// 设置seq日志存放映射的路径
/usr/local/sunlight/docker/seq/data

// 5341 代码里调用的路径
// 80 查看日志的UI
docker run --name seq -d -e ACCEPT_EULA=Y -e SEQ_FIRSTRUN_ADMINPASSWORDHASH="$SeqPwd" -v /usr/local/sunlight/docker/seq/data:/data --memory=512m --memory-swap=512m -e SEQ_CACHE_SYSTEMRAMTARGET=0 -p 12000:80 -p 5341:5341 datalust/seq

// nginx 进行配置转发
netstat -ntlp|grep 12000


// nginx中添加如下转发规则
location /seq {
proxy_pass http://127.0.0.1:12000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
add_header Cache-Control no-cache;

# 解决潜在的路径问题
rewrite ^/seq(/.*)$ $1 break;
}

// nginx配置完毕后,重启一下nginx
nginx -s reload

// 创建seq apikey
https://www.cnblogs.com/RainFate/p/16869403.html

```

0 comments on commit d704a29

Please sign in to comment.