Skip to content

Instantly share code, notes, and snippets.

View manojbadam's full-sized avatar
🎯
Focusing

Manoj Badam manojbadam

🎯
Focusing
  • Adobe
  • Sunnyvale, CA
View GitHub Profile
@dharmab
dharmab / kubecon.md
Last active December 13, 2018 22:13

Kubecon 2018 Diary

bellamko@adobe.com / unfiltered / limited distribution

2018-12-11

Keynote

Nothing unexpected. That zoo story was weird.

@joyrexus
joyrexus / README.md
Last active March 18, 2024 11:03
local webhook testing

We can test webhook callbacks with a little http server and a localtunnel.

Run server.js to spin up a local http server on port 8080. It just exposes a top-level route and will print the received header and payload of any request. Then create a localtunnel to have a non-local url that proxies all requests to localhost:8080.


First, install dependencies with npm install.

Then start the express server with npm start.

@ncdc
ncdc / kube-proxy.txt
Last active March 8, 2019 05:40
Example `kube-proxy --help` output showing the default config file and describing all config fields
$ kube-proxy --help
The Kubernetes network proxy runs on each node. This
reflects services as defined in the Kubernetes API on each node and can do simple
TCP,UDP stream forwarding or round robin TCP,UDP forwarding across a set of backends.
Service cluster ips and ports are currently found through Docker-links-compatible
environment variables specifying ports opened by the service proxy. There is an optional
addon that provides cluster DNS for these cluster IPs. The user must create a service
with the apiserver API to configure the proxy.
Usage:
@devStepsize
devStepsize / slack_slash_cmd.py
Created April 21, 2016 23:12
Server-side logic to handle a Slack slash command using Python and Flask
'''
This is an example of the server-side logic to handle slash commands in
Python with Flask.
Detailed documentation of Slack slash commands:
https://api.slack.com/slash-commands
Slash commands style guide:
https://medium.com/slack-developer-blog/slash-commands-style-guide-4e91272aa43a#.6zmti394c
'''
@leommoore
leommoore / mongodb_setting_up_a_replica_set.md
Last active May 26, 2025 15:57
MongoDB - Setting up a Replica Set

#MongoDB - Setting up a Replica Set

cd \mongodbdir\

mkdir db1
mkdir db2
mkdir db3

###Primary mongod --dbpath ./db1 --port 30000 --replSet "demo"

@drewolson
drewolson / reflection.go
Last active November 21, 2024 15:11
Golang Reflection Example
package main
import (
"fmt"
"reflect"
)
type Foo struct {
FirstName string `tag_name:"tag 1"`
LastName string `tag_name:"tag 2"`
@shadowbrain
shadowbrain / parse json with sed
Created December 16, 2011 15:32
parse json key:value with sed
## Example: Grab the value for the MYSQL_USER key
User=$( sed -n 's/.*"MYSQL_USER": "\(.*\)",/\1/p' /var/lib/credentials.json )
## Example: Grab the value for the MYSQL_PASSWORD key
Passwd=$( sed -n 's/.*"MYSQL_PASSWORD": "\(.*\)",/\1/p' /var/lib/credentials.json )