k3s+kuboard快速搭建K8s生产环境集群
提前准备3台机器,可以是云服务器,安装机器要求,请参考:https://docs.k3s.io/zh/installation/requirements 我准备了:192.168.2.195(master node)192.168.2.226(agent node1)192.168.2.227(agent node2) 在开始之前,我们先安装docker: #禁用防火墙systemctl disable firewalld#禁用selinxsetenforce 0#安装所需的软件包。yum-utils 提供了 yum-config-manager ,并且 device mapper 存储驱动程序需要 device-mapper-persistent-data 和 lvm2。sudo yum install ...
自制一键安装环境oneshell_v1.0.sh
echo install env...yum -y install gcc gcc-c++ make libtool zlib zlib-devel openssl openssl-devel pcre pcre-devel#下载Nginxecho downloading nginx-1.18.0wget -c https://nginx.org/download/nginx-1.18.0.tar.gz#安装 nginxecho install nginx-1.18.0tar -zxvf nginx-1.18.0.tar.gzcd nginx-1.18.0./configure --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_v2_module --with-stream --with-http_gzip_static_modulemake &...
ELK/EFK中ES使用IK分词器的方式步骤
1. 安装ES同时安装IK提前下载好IK分词器(版本和ES保持 一致):https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v6.8.0/elasticsearch-analysis-ik-6.8.0.zip下载后,在plugins下面创建文件夹IK,把ZIP解压到IK里面使用DOCKER启动ES:es: container_name: es image: docker.elastic.co/elasticsearch/elasticsearch:6.8.0 privileged: true ports: - "9200:9200" volumes: - ./efk/es/data:/usr/share/elasticsearch/data - ./efk/es...
kibana6.8.0禁用不用的模块
server.port: 5601server.host: "0.0.0.0"server.name: "kibana"elasticsearch.hosts: ["http://es:9200"]elasticsearch.ssl.verificationMode: none#elasticsearch.ssl.certificateAuthorities: ["/data/kibana/config/newfile.crt.pem"]elasticsearch.preserveHost: truekibana.index: ".kibana"i18n.locale: "en"server.defaultRoute: "/app/kibana#/discover"elasticsearch.username: "elastic"elasticsearch.password: "xxxxxxxxxxxxxxxxx"# 禁用可视化和仪表板xpack.monitori...
adGuardHome自定义规则
||example.org^ – 拦截 example.org 域名及其所有子域名@@||example.org^ – 放行 example.org 及其所有子域名127.0.0.1 example.org – AdGuard Home 现在将会把 example.org(但不包括它的子域名)解析到 127.0.0.1。! 这是一行注释 – 只是一条注释# 这也是一行注释 – 只是一条注释/REGEX/ – 阻止访问与example_regex_meaning匹配的域 参考:sub.adtchrome.com/adt-chinalist-easylist.txt
vue/react/node/vite/npm/yarn build自动更新版本号
//根目录 创建 version.js//安装 dayjs 或者 momentjs//修改package.json中build script为: node version.js & vite build//version.js如下:import fs from "fs";import dayjs from "dayjs";const getPackageJson = () => { let data = fs.readFileSync('./package.json') //fs读取文件 return JSON.parse(data) //转换为json对象}let packageData = getPackageJson()packageData.version = dayjs().format('YYYYMMDDHHmm');fs.writeFile( './package.j...
使用tengine代替Nginx
有了nginx,为什么还要用tengine?因为: #下载 https://tengine.taobao.org/wget https://tengine.taobao.org/download/tengine-3.0.0.tar.gztar -zxvf tengine-3.0.0.tar.gzcd tengine-3.0.0#安装依赖yum install pcre-develyum -y install openssl openssl-devel./configure --add-module=modules/ngx_http_upstream_check_module#./configure --add-module=./nginx_upstream_check_module --with-http_ssl_module --with-http_v2_module --with-stream --with-http_gz...
nginx添加nginx_upstream_check_module
#cd nginx source foldercd /usr/local/nginx/nginx-1.18.0wget https://github.com/yaoweibin/nginx_upstream_check_module/archive/refs/heads/master.zipunzip master.zipmkdir nginx_upstream_check_modulemv nginx_upstream_check_module/* ./nginx_upstream_check_module/./configure --add-module=./nginx_upstream_check_module#if need ssl#./configure --add-module=./nginx_upstream_check_module --with-http_ssl_module#backup old nginx filemv /usr/local/n...
调用企微接口报403 API Forbiden 无权限 的错误
https://work.weixin.qq.com/wework_admin/frame#/customer/analysis 需要修改应用权限 :
github连接超时:Connection closed by remote host
git pull 或者git push的时候,提示:kex_exchange_identification: Connection closed by remote hostConnection closed by 127.0.0.1 port 22fatal: Could not read from remote repository.Please make sure you have the correct access rights 使用命令:ssh -T git@github.com 检测如果测试成功,请关闭代理试试,如果测试失败,请向下配置:将ssh的22端口改为使用443在等待git pull命令超时之后报出了类似: ssh: connect to host github.com port 22: Connection timed out的错误!原因是: s...