比价助手机器人docker快速部署

对于商品比价是个不错的购买商品的方法,可以给我们是否值得入手这件商品提供决策。各大商城有这方面数据但不会免费给分享出来,第三方网站有相关服务,但体验不好,相关api也太贵,这次找到了大佬免费提供的对话bot的比价助手——傻妞助手,应该是内置比价api吧!目前来说数据还可以值得参考的,用了docker部署,很快搞定! 一、部署傻妞助手bot 项目地址:GitHub - cdle/sillyGirl: 傻妞机器人 一键安装:支持linux arm64和amd64位 1 2 cd /opt s=sillyGirl;a=arm64;if [[ $(uname -a | grep "x86_64") != "" ]];then a=amd64;fi ;if [ ! -d $s ];then mkdir $s;fi ;cd $s;wget https://github.com/cdle/${s}/releases/download/main/${s}_linux_$a -O $s && chmod 777 $s;pkill -9 $s;$(pwd)/$s 在目录/etc/sillyGirl下新建sets.conf可以进行初始化配置 主要是配置管理员账号等,也可以通过对话配置 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 ### 一些基础设置 ### # 傻妞机器人名 set sillyGirl name 傻妞 # 傻妞http服务端口 set sillyGirl port 800 # 傻妞消息撤回等待时间,单位秒 set sillyGirl duration 5 # 傻妞自动升级是否通知 set sillyGirl update_notify true # 是否开启傻妞自动更新 set sillyGirl auto_update false # 傻妞内置赞赏码 set sillyGirl appreciate https://gitee....

创建: 2022-02-06 | 更新: 2024-08-27 | 字数: 1060字 | 时长: 5分钟 | 作者:张三

Hugo 自动更新文章修改时间

config配置文件里加上如下参数: 1 2 3 4 5 6 frontmatter: lastmod: - lastmod - :git - :fileModTime - :default 依次取的顺序为: lastmod :最后提交时间 :git: 根据git提交版本时间 :fileModTime:文件修改时间 Configure Hugo | Hugo 写的都有,but是英文的🙃

创建: 2022-01-22 | 更新: 2024-08-27 | 字数: 28字 | 时长: 1分钟 | 作者:张三

Docker Compose部署filebrowser

在linuxserver服务器上安装 环境:docker、docker- compose 需要了解docker基本知识,不懂可以翻翻以前的博客或者搜下教程学习 filebrowser 官网上给的是docker命令执行的,但用compose习惯了,所以转换了一下格式,但是这里有个坑,官网也提示了 By default, we already have a configuration file with some defaults so you can just mount the root and the database. Although you can overwrite by mounting a directory with a new config file. If you don’t already have a database file, make sure to create a new empty file under the path you specified. Otherwise, Docker will create an empty folder instead of an empty file, resulting in an error when mounting the database into the container. 翻译过来就是需要提前创建所需的文件和文件夹,否则,Docker会创建一个空的文件夹而不是空的文件,导致在将数据库挂载到容器中时出现错误!这点一定要注意啊!!! 1、创建docker-compose文件 内容如下: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 version: '3.3' services: filebrowser: image: filebrowser/filebrowser:s6 container_name: filebrowser volumes: - ./root:/srv - ./database/filebrowser.db:/database/filebrowser.db - ./settings.json:/config/settings.json environment: - PUID=0 - PGID=0 ports: - '8080:80' restart: always 2、创建默认文件和文件夹 对照上述docker-compose的路径,需要在当前目录创建 settings.json 文件,内容如下: 1 2 3 4 5 6 7 8 { "port": 80, "baseURL": "", "address": "0.0.0.0", "log": "stdout", "database": "/database/filebrowser.db", "root": "/srv" } 在当前目录创建 database/filebrowser....

创建: 2022-01-21 | 更新: 2024-08-27 | 字数: 243字 | 时长: 2分钟 | 作者:张三

docker 生成自己的镜像

看过前面的文章知道,大佬的库仓库也锁了,不能pull,只能换取仓库地址才行,为了一劳永逸,索性换了自己的库,只谈技术,不谈其他… 1、创建Dockerfile文件 比较懒,直接把大佬的Dockerfile拉来换了仓库地址,rsa记着也要换 换完在当前目录 docker build -t jd_scripts . 直接生成自己的image docker images 查看镜像 2、修改docker-compose文件 修改docker-compose里面的仓库地址为自己的地址,其他参数不用变 docker-compose up -d 启动镜像 完美运行! 继续躺平。 建议学学docker,真的好强大! 附上一个不错的docker教程 Docker —— 从入门到实践

创建: 2021-06-21 | 更新: 2024-08-27 | 字数: 26字 | 时长: 1分钟 | 作者:张三

girde simple修改添加支持侧边栏目录

修改主题文件支持侧边栏目录 simple主题整体还行,但文章无侧边栏目录,一般写的技术性文章很长,就需要侧边栏目录和这个功能了,在网上搜了一下资料,对于前端小学生的我费了好长时间才搞定,记录一下过程。 1、修改post.ejs文件 head新增 <script src="https://cdn.bootcss.com/highlight.js/9.12.0/highlight.min.js"></script> 搜索<%- post.content %>复制一下代码覆盖copy 1 2 3 4 5 6 7 8 <div class="post-content-wrapper"> <div class="post-content" v-pre> <%- post.content %> </div> <div class="toc-container"> <%- post.toc %> </div> </div> 新增高亮js 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 <script> hljs.initHighlightingOnLoad() let mainNavLinks = document.querySelectorAll(".markdownIt-TOC a"); // This should probably be throttled. // Especially because it triggers during smooth scrolling. // https://lodash.com/docs/4.17.10#throttle // You could do like... // window.addEventListener("scroll", () => { // _.throttle(doThatStuff, 100); // }); // Only not doing it here to keep this Pen dependency-free. window.addEventListener("scroll", event => { let fromTop = window.scrollY; mainNavLinks.forEach((link, index) => { let section = document.getElementById(decodeURI(link.hash).substring(1)); let nextSection = null if (mainNavLinks[index + 1]) { nextSection = document....

创建: 2021-06-06 | 更新: 2024-08-27 | 字数: 349字 | 时长: 2分钟 | 作者:张三

云服务器docker搭建自动领京豆bot互动指令

使用docker部署自动领金豆bot脚本 使用的版本: 服务器:centos 8 docker: 20.10.6 docker-compose: 1.27.4 1、服务器安装docker,docker-compose 推荐使用centos服务器安装docker、docker-compose Docker安装 国内一键安装 curl -sSL https://get.daocloud.io/docker | sh 国外一键安装 curl -fsSL https://get.docker.com | bash -s docker --mirror Aliyun docker-compose安装 $ sudo curl -L "https://github.com/docker/compose/releases/download/1.24.1/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose 要安装其他版本的 Compose,请替换 1.24.1。 最新发行的版本地址:https://github.com/docker/compose/releases。 将可执行权限应用于二进制文件: $ sudo chmod +x /usr/local/bin/docker-compose 创建软链: $ sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose 通过docker-compose version查看docker-compose版本,确认是否安装成功。 2、安装jd_scripts 创建一个目录jd_scripts用于存放备份配置等数据,迁移重装的时候只需要备份整个jd_scripts目录即可 需要新建的目录文件结构参考如下: 1 2 3 4 5 6 jd_scripts ├── logs │ ├── XXXX.log │ └── XXXX.log ├── my_crontab_list.sh └── docker-compose.yml jd_scripts/logs建一个空文件夹就行 jd_scripts/docker-compose.yml 参考内容如下(自己动手能力不行搞不定请使用默认配置): 根据文档一步一步下去就ok了,下面主要记录下可能用到的命令 目录文件配置好之后在 jd_scripts目录执行。 docker-compose up -d 启动(修改docker-compose.yml后需要使用此命令使更改生效); docker-compose logs 打印日志; docker-compose logs -f 打印日志,-f表示跟随日志; docker logs -f jd_scripts 和上面两条相比可以显示汉字; docker-compose pull 更新镜像; docker-compose stop 停止容器; docker-compose restart 重启容器; docker-compose down 停止并删除容器; 3、开代理机器,激活tg-bot 这里是个大坑,拿个小本本记下来,其实就是docker内代理宿主机代理的问题 由于众所周知的原因,国内的机器不能访问tg,而又想使用tg-bot来控制,无奈,国外机子太贵(穷),最低也要5美刀!遂买国内机子开代理使用 1、买国内机器,推荐大厂的 这里应该放各大厂的aff的,留个坑 2、安装clash 一直在使用clash,直接网上搜索clash下载 ,找到对应版本下载,博主用的是centos,下载linux-amd64的 1、下载clash,最新版本可去官网找 1 wget https://github.com/Dreamacro/clash/releases/download/v0.19.0/clash-linux-amd64-v0.19.0.gz 2、解压 1 gzip -d clash-linux-amd64-v0.19.0.gz 3、移动至usr/bin/clash并重命名为clash 1 sudo mv clash-linux-amd64-v0.19.0 /usr/bin/clash 4、赋予clash运行权限 1 sudo chmod +x /usr/bin/clash 5、检查是否安装成功 1 clash -v 3、创建配置文件、安装控制面板 1.创建配置文件目录 1 mkdir -p /etc/clash/ 2....

创建: 2021-04-30 | 更新: 2021-04-30 | 字数: 602字 | 时长: 3分钟 | 作者:张三