- 博客(78)
- 资源 (7)
- 收藏
- 关注
原创 vitepress postRender修改markdown内容
vitepress 动态修改markdown内容vitepress 统一修改markdown内容。
2024-09-06 14:59:15 272
原创 kubekey在ubuntu24实现kubernetes快速安装
ubuntu24,kubekey,kubesphere,kubernetes
2024-07-10 11:07:09 467 1
原创 vscode免密登录无效
vscode 免密 登录alamLinux8/CentOS8 配置正确,但是登录无效,可能是selinux 的原因解决方法:#查看 selinuxgetenforce#关闭 selinuxsetenforce 0#开启 selinuxsetenforce 1#永久关闭vi /etc/selinux/configSELINUX=disabled#SELINUX=enforcing...
2022-04-22 10:29:20 500
原创 docker pulsar standalone tls
docker pulsar standalone tlsdocker run --name pulsar \ -p 6650:6650 \ -p 8080:8080 \ -p 6651:6651 \ -p 8443:8443 \ -v /root/pulsar/data:/pulsar/data \ -e PULSAR_PREFIX_brokerServicePortTls=6651 \ -e PULSAR_PREFIX_webServicePortTls=8443
2022-03-23 15:56:21 3754
原创 angular ngFor object
angular >= 6.1<div *ngFor="let item of object | keyvalue"> {{item.key}}:{{item.value}}</div>
2020-09-24 11:19:42 458
原创 requests请求重定向后获取headers
requests请求重定向后,获取重定向地址的headers,cookieimport requestsresponse = requests.post(url, data, headers, verify=False)for his in response.history: print(his.headers) print(his.headers['Set-Cookie']) print(his.cookies)...
2020-07-09 16:12:01 1630
原创 [ElasticSearch7] 批量导入
import csvfrom elasticsearch import Elasticsearchfrom elasticsearch import helperses=Elasticsearch(hosts='http://localhost',port=9200)def gendata(): with open('scripts/assets.csv', 'r', enc...
2020-03-30 15:51:39 1252
原创 tensorflow2 测试数据集下载
思路设置本机代理 http://127.0.0.1:1087 ,科学上网操作关掉ssl验证errorException: URL fetch failure on https://storage.googleapis.com/tensorflow/tf-keras-datasets/mnist.npz: None -- [SSL: CERTIFICATE_VERIFY_FAILED] ...
2019-05-15 18:43:44 3223
原创 linux 下chrome 73 自动打开flash 设置
linux 下chrome 73 自动打开flash 设置chrome flash auto allow指定chrome的flash官网下载flash, 建议下载ppapi的: https://www.flash.cn/然后指定libpepflashplayer.so路径,即可。python 代码 browers_options = Options() b...
2019-05-04 00:28:06 742
原创 CentOS7Selinux设置
Selinuxvi /etc/sysconfig/selinuxSELINUX=enforcing改为SELINUX=disabled设置setenforce 0查看getenforcevi /etc/nginx/nginx.confuser root;nginx在开启Selinux时自定义目录chcon -R -u system_u /usr/share/nginx/ht...
2019-04-19 11:46:59 1970
原创 elasticsearch 7 单机配置
elasticsearch 7.0.0 新版更新,填个坑单机部署提示:error1:[cluster.initial master nodes] is empty on this nodeerror:2the default discovery settings are unsuitable for production use; at least one of [discover...
2019-04-18 14:50:26 3349
原创 inotify_add_watch(7, /dev/dm-4, 10) failed: No such file or directory
centos7 daoker 安装异常。11月 12 15:04:49 localhost.localdomain systemd-udevd[7722]: inotify_add_watch(7, /dev/dm-4, 10) failed: No such file or directory11月 12 15:04:49 localhost.localdomain dockerd[781...
2018-11-12 15:23:25 5249 1
原创 记一次使用Docker离线部署
安装docker参考官方网站一步一步来就行了。 Get Docker Ubuntu重要操作如下:sudo apt-get updatesudo apt-get install \ apt-transport-https \ ca-certificates \ curl \ software-properties-commoncurl -fsSL...
2018-04-10 15:58:08 1634
原创 elasticsearch-py update
es_dashed_info = ES.search(index='dashed', doc_type='adlab', q='code:"%s"' % info)dashed_info = es_dashed_info['hits']['hits'][0]['_source']res = ES.update(index='dashed', doc_type='adlab', id=inf
2018-02-06 14:55:26 224
原创 docker 开发 python 配置
纠结python2 or python3 , 当然是全都用了,好吧,docker 隔离,啥都不说了。debug 是个坑,基本上就 pdb 和 print 了, 默默选择了print, pdb不会用啊。 单步,远程调试,可以试试 pycharm。 如果打算用 vscode 哪就好好print吧。vscode 提供都 ptvsd 也只能单步打印,没有监控,没有变量可看,T_T.
2018-01-22 19:13:12 1244
原创 digdome.sh
#!/bin/bashcleardome=.tnsroot.cnfor((i=0;i<60010;i++))dosleep 1barcode=$[69000000+$i]echo $barcodedig @218.241.119.6 $barcode$dome NAPTRif(($i>600000))thenecho $iecho '-------Once again---------
2017-12-14 11:04:34 193
原创 MySQL 运维
MySQL 主从跳过 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1;修复表 REPAIR TABLE aaa;MySQL导出存储过程 mysqldump -h localhost -u root -p -t -d -R db_tms_two > D:\cccc.sql mysqldump -hlocalhost -uroot -ntd -R hqgr > hqgr
2017-12-14 11:01:13 986
原创 mongodb 笔记
–进入mongo mongo–添加永久用户 use admin; db.addUser(‘username’, ‘password’);–登录库 use admin; db.auth(‘username’, ‘password’);–删除库 user cuckoo; db.dropDatabase();
2017-12-14 10:58:16 275
原创 添加静态路由
windows route -p add 172.16.2.0 mask 255.255.0.0 192.168.10.220linux route add –net 172.16.2.0 netmask 255.255.0.0 gw 192.168.10.220
2017-12-14 10:55:26 382
原创 ubuntu 14 本地源制作
注意事项root用户 更新源目录:/var/cache/apt/archives/ 新建本地源目录:~/packs操作修改源文件归属 sudo chown root:root -R /var/cache/apt/archives/*复制文件 sudo cp -r /var/cache/apt/archives/* ~/packs建立Packages.gz包建立Packa
2017-12-14 10:48:28 516
原创 ubuntu14启用root登录
设置密码 sudo passwd root配置root登录 vim /etc/lightdm/lightdm.conf 如果没有lightdm.conf 自行创建。[SeatDefaults]# 启动后以root身份自动登录autologin-user=rootgreeter-session=unity-greeteruser-session=ubuntu# 手工输入登陆系统的用户名和
2017-12-14 10:41:52 768
原创 Dell XPS 8900 Install Linux mint 18
说明搞了机器,倒腾个linux 用,debian,deepin 安装不上,ubuntu 界面太丑,最后选了linux mint 18.2, 也是各种坑bug开机和关机会无限循环输出如下内容:printk messages dropped ** [78.xxxxxx] pcieport 0000:00:1c.0: device[8086:a110] error status/mask=00000001
2017-11-29 17:30:04 1905
原创 CentOS 6.5 自启动无效的问题
遇见网上有好多答案,也有好多方法。 基本都是/etc/rc.local 权限的问题。 不同我遇到的也是权限的问题,但是我的是用户目录权限的问题, 自启动时没有权限读取 对应的目录。 后来我把启动脚本包括在 sh 文件中 放到 /etc/init.d/ 下 启动就可以了。还有我的python 可执行是放在 /usr/local/bin/python 下, 也导致了开机启动无效的问题。 后来我软链接到
2017-11-03 19:23:38 1422
原创 flexbox 笔记
容器属性flex-direction 属性决定主轴的方向,如:从上到下,从左到右。flex-wrap 属性是控制如何换行。flex-flow 属性是flex-direction 属性 和 flex-wrap 属性的缩写。justify-content 属性定义了项目在主轴上的对齐方式。默认即,左中右对齐。align-items 属性定义项目在交叉轴上如何对齐。默认即,上中下对齐。align-cont
2017-10-27 12:49:51 225
原创 mongodb 导出和备份
mongodb 3.4 导出和备份导出mongodump -h 127.0.0.1:27017 -d dbname -o back_file_path备份mongorestore -h 127.0.0.1:27017 -d dbname back_file_path参考http://www.runoob.com/mongodb/mongodb-mongodump-mongorestore.html
2017-10-26 15:05:29 267
原创 wkhtmltopdf error
说明html转个pdf 一堆bug , 有一个记录一个.. python27的, 很抱歉我只找到了原因,没找到解决方案。bug执行>>> import pdfkit>>> pdfkit.from_file('aa.html', 'out.pdf')errorTraceback (most recent call last): File "<stdin>", line 1, in <modu
2017-10-24 11:01:46 7506 7
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人