Skip to content

Instantly share code, notes, and snippets.

View kukat's full-sized avatar

Cheng Yao kukat

View GitHub Profile
@kukat
kukat / agent-75593.json
Created January 8, 2018 09:42
agent-75593
{
"advisorId": "75593",
"advisorCode": "040001-01-075593",
"status": "active",
"type": {
"code": "AGENT",
"name": "Agent"
},
"party": {
"type": "Person",
@kukat
kukat / keycloak-link.js
Created January 7, 2018 14:10
Client Initiated Account Linking
@kukat
kukat / gist:58a10cc83728625140bec5895cd19a9f
Created December 27, 2017 18:35
start new chrome instance with proxy
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --user-data-dir=/tmp/chrome-with-proxy --proxy-server=localhost:9999 --disable-restore-session-state --no-default-browser-check --disable-popup-blocking --disable-translate --start-maximized --disable-default-apps --disable-sync --enable-fixed-layout --no-first-run --noerrdialogs
https://api.m.jd.com/client.action?functionId=leGaoDrawCoupon&client=wh5&clientVersion=1.0.0&body=%7B%22activityId%22%3A%222ZLg7hg92UJgJnRcQzRYiTceBT3V%22%2C%22pageId%22%3A%22143170%22%2C%22moduleId%22%3A%224PWVRtMJhmRHkFqHzfP94mJT4qmu%22%7D&_=&callback=jsonp1
jsonp1({"subCode":"3-10","returnMsg":"未中奖2","userLevel":"105","userLevelContent":"钻石会员","riskValue":"0","code":"0","msg":null})

Auto let's encrypt on Synology

nginx-proxy

docker run -d -p 20080:80 -p 20443:443 --name  jwilder-nginx-proxy -v /volume1/docker/jwilder-nginx-proxy/certs:/etc/nginx/certs:ro -v /etc/nginx/vhost.d -v /usr/share/nginx/html -v /var/run/docker.sock:/tmp/docker.sock:ro --label com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy=true jwilder/nginx-proxy:alpine

letsencrypt-nginx-proxy-companion

@kukat
kukat / hosts.txt
Created March 22, 2017 03:38
NetEase Music hosts
wanproxy.127.net
music.163.com
p3.music.126.net
p4.music.126.net
m7.music.126.net
m8.music.126.net
web.push.126.net
@kukat
kukat / Kaying summary
Created January 11, 2017 16:07
Z7-SP5D1
操作系统:Microsoft Windows 10 专业版 (BUILD:14393) (64 位)
CPU信息:Intel(R) Core(TM) i5-6300HQ CPU @ 2.30GHz
步进:3 型号:E 系列:6 扩展型号:5E 扩展系列:6
主板信息:Notebook () P65xRP
内存信息:8.0 GB (8.0 GB / )
显卡信息:Intel(R) HD Graphics 530
NVIDIA GeForce GTX 1060
硬盘信息:HGST HTS541010A9E680 (1.0 TB)
_part_get_partition] 0
[mt_part_get_partition] PRELOADER
[mt_part_get_partition] 0
[mt_part_get_partition] PRELOADER
[mt_part_get_partition] 0
@kukat
kukat / dock.command
Last active June 30, 2016 04:49
How to auto hide the dock and remove its delay on macOS
defaults write com.apple.dock autohide -bool true && defaults write com.apple.dock autohide-delay -float 0 && defaults write com.apple.dock autohide-time-modifier -float 0 && killall Dock
#!/bin/sh
files=$(git diff HEAD --name-only --diff-filter=ACMR -- apps/realestate/test/**Spec.swift)
pass=true
fits=""
if [ "$files" != "" ]; then
echo "Checking 'fit', 'fcontext' and 'fdescribe' in unit tests..."
echo ""
for file in ${files}; do