Skip to content

Instantly share code, notes, and snippets.

@eli007s
eli007s / mac-setup-redis.md
Created Mar 19, 2020 — forked from tomysmile/mac-setup-redis.md
Brew install Redis on Mac
View mac-setup-redis.md

type below:

brew update
brew install redis

To have launchd start redis now and restart at login:

brew services start redis
@eli007s
eli007s / kubectl.md
Created Aug 18, 2019 — forked from so0k/kubectl.md
Playing with kubectl output
View kubectl.md

Kubectl output options

Let's look at some basic kubectl output options.

Our intention is to list nodes (with their AWS InstanceId) and Pods (sorted by node).

We can start with:

kubectl get no
View keybase.md

Keybase proof

I hereby claim:

  • I am eli007s on github.
  • I am eli007s (https://keybase.io/eli007s) on keybase.
  • I have a public key ASCH95tnMDW63FniXr8u1jOCx2v24G67_Y--HrMioHNgBAo

To claim this, I am signing this object:

View Client.swift
import Foundation
import Alamofire
import RxSwift
import RxCocoa
protocol ClientProtocol {
func request<Response>(_ endpoint: Endpoint<Response>) -> Single<Response>
}
@eli007s
eli007s / nginx-unzip-module_good.patch
Created Nov 27, 2016 — forked from fffonion/nginx-unzip-module_good.patch
nginx-unzip-module, NODIR, NOCASE mod
View nginx-unzip-module_good.patch
diff --git a/ngx_http_unzip_module.c b/ngx_http_unzip_module.c
index 771e1dc..00ea0f1 100644
--- a/nginx-unzip-module/ngx_http_unzip_module.c
+++ b/nginx-unzip-module/ngx_http_unzip_module.c
@@ -224,7 +224,7 @@ static ngx_int_t ngx_http_unzip_handler(ngx_http_request_t *r)
zip_stat_init(&zip_st);
/* let's check what's the size of a file. return 404 if we can't stat file inside archive */
- if (0 != zip_stat(zip_source, unzipextract_path, 0, &zip_st)) {
+ if (0 != zip_stat(zip_source, unzipextract_path, ZIP_FL_NODIR|ZIP_FL_NOCASE, &zip_st)) {
View new_gist_file_0
MODEL max_connections innodb_buffer_pool_size
--------- --------------- -----------------------
t1.micro 34 326107136 ( 311M)
m1-small 125 1179648000 ( 1125M, 1.097G)
m1-large 623 5882511360 ( 5610M, 5.479G)
m1-xlarge 1263 11922309120 (11370M, 11.103G)
m2-xlarge 1441 13605273600 (12975M, 12.671G)
m2-2xlarge 2900 27367833600 (26100M, 25.488G)
m2-4xlarge 5816 54892953600 (52350M, 51.123G)
@eli007s
eli007s / 0_reuse_code.js
Created Jul 18, 2016
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
You can’t perform that action at this time.