wkt blog

  • About
  • Video
  • About
  • Video

Category: 其他

读取txt大文件并插入到mysql

by admin/February 13, 2021February 13, 2021/其他

文件6.9更新总库.txt的大小是18G, 大概有7亿条数据, 需要写入到mysql并提供查询功能。 步骤 1. 建表 建表:建立5个表分别是qq_0, qq_1, qq_2, qq_3, qq_4, 表结构一致, 先不建立索引. 耗时0分钟 create database ku default charset utf8mb4; CREATE TABLE qq_0 ( id INT(11) PRIMARY KEY AUTO_INCREMENT, qq_number VARCHAR(64) DEFAULT ”, mobile VARCHAR(64) DEFAULT ” ); CREATE TABLE […]

自建Pypi反向代理服务器

by admin/December 4, 2020January 9, 2021/其他

用于机器无法联网, 但是局域网内有其他电脑可以联网的情况下使用pip安装依赖包. 使用Nginx反向代理即可: server { listen 38888 default_server; index index.html index.htm index.nginx-debian.html; server_name _; location /simple { proxy_pass https://pypi.doubanio.com; } location /packages { proxy_pass https://pypi.doubanio.com; } } 安装时指定trusted-host, 比如: pip install requests -i http://ip:18888/simple –trusted-host=*

Allow All Content Security Policy

by admin/November 12, 2020November 27, 2020/其他

<meta http-equiv=”Content-Security-Policy” content=”default-src * data: blob: filesystem: about: ws: wss: ‘unsafe-inline’ ‘unsafe-eval’ ‘unsafe-dynamic’; script-src * data: blob: ‘unsafe-inline’ ‘unsafe-eval’; connect-src * data: blob: ‘unsafe-inline’; img-src * data: blob: ‘unsafe-inline’; frame-src * data: blob: ; style-src * data: blob: ‘unsafe-inline’; font-src […]

How to fetch all Git branches

by admin/August 26, 2020August 27, 2020/其他

for remote in `git branch -r`; do git branch –track ${remote#origin/} $remote; done

手动申请 Let’s Encrypt 泛域名证书

by admin/August 11, 2020August 12, 2020/其他

docker run -it –rm –name certbot -v $PWD:/etc/letsencrypt certbot/certbot certonly –manual –preferred-challenges=dns-01 –server=https://acme-v02.api.letsencrypt.org/directory 回车后按照提示输入 , 最后配置txt解析即可生成证书和密钥, 有效期三个月

A Desktop-Agnostic Way to Change DNS Server

by admin/July 26, 2020July 26, 2020/其他

Editing ‘/etc/parse.conf’ is not recommended any more because the content will be reset after restart. Open a terminal window and go to the Network Manager connections profile directory. cd /etc/NetworkManager/system-connections/ Then list connection names available on your system. ls As […]

Stop trying to use JWT unnecessarily

by admin/June 21, 2020June 23, 2020/其他

JWT is a very common authentication method. Some people say you should never use it, while others say it’s amazing. Today, I just want to talk about the disadvantages and why using JWT in web applications is not always a […]

Cordova: get 404 error for the all ajax request on Android device

by admin/May 21, 2020May 21, 2020/其他

The app build with cordova is installed on an Android device, all ajax requests are 404(NotFound). But debugging in chrome works fine. This problem can be solved by reinstalling cordova-plugin-whitelist remove: cordova plugin remove cordova-plugin-whitelist reinstall: cordova plugin add cordova-plugin-whitelist

DNS over Https(DOH)

by admin/April 4, 2020May 20, 2020/其他

DNS over HTTPS (DoH) is a protocol for performing remote Domain Name System (DNS) resolution via the HTTPS protocol. A goal of the method is to increase user privacy and security by preventing eavesdropping and manipulation of DNS data by […]

Install pymssql for Mac OS

by admin/March 15, 2020April 16, 2020/其他

Install Python runtime and pip package manager a. Go to python.org b. Click on the appropriate Mac installer pkg link. c. Once downloaded run the pkg to install Python runtime Open terminal Install Homebrew package manager ruby -e “$(curl -fsSL […]

Posts navigation

1 2 … 9

Recent Posts

  • 读取txt大文件并插入到mysql
  • 自建Pypi反向代理服务器
  • Allow All Content Security Policy
  • How to fetch all Git branches
  • 手动申请 Let’s Encrypt 泛域名证书

Archives

  • February 2021
  • December 2020
  • November 2020
  • August 2020
  • July 2020
  • June 2020
  • May 2020
  • April 2020
  • March 2020
  • February 2020
  • December 2019
  • November 2019
  • October 2019
  • September 2019
  • August 2019
  • July 2019
  • June 2019
  • May 2019
  • April 2019
  • March 2019
  • January 2019
  • December 2018
  • November 2018
  • September 2018
  • August 2018
  • May 2018
  • April 2018
  • March 2018
  • February 2018
  • January 2018
  • November 2017
  • October 2017
  • September 2017
  • June 2017
  • May 2017
  • April 2017
  • April 2016

友情链接

  • Harttle
  • 张俊杰的微博客
  • 蔣振飞的博客
  • 饲养员的窝
Proudly powered by WordPress | Theme: ShowMe by NEThemes.