Skip to content

Instantly share code, notes, and snippets.

👨‍💻
at work

Suraj Narwade surajnarwade

👨‍💻
at work
Block or report user

Report or block surajnarwade

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View create-user-ocp4.sh
#!/bin/bash
HTPASSWD_FILE="./htpass"
USERNAME="suraj1"
USERPASS="developer"
HTPASSWD_SECRET="htpasswd-secret1"
htpasswd -cb $HTPASSWD_FILE $USERNAME $USERPASS
oc get secret $HTPASSWD_SECRET -n openshift-config &> /dev/null
View pod.yml
apiVersion: v1
kind: Pod
metadata:
labels:
run: nginx
name: nginx
spec:
containers:
- image: nginx
name: nginx
@surajnarwade
surajnarwade / operatorTalks.md
Created Jan 25, 2019
Talks related to Controllers & Operators
View operatorTalks.md
@surajnarwade
surajnarwade / nmcli-wifi.md
Last active Nov 16, 2018
Control wifi using nmcli
View nmcli-wifi.md

WI-FI using nmcli

  • Check wifi status
nmcli radio wifi
  • Turn on the wifi
View tmuxcheatsheet.md

type tmux in terminal

Windows:

  • Create new window: Ctrl+b c
  • Move to next window: Ctrl+b n
  • Move to previos window: Ctrl+b p
  • List all wondows: Ctrl+b w

Panes/Split:

View pointer logics
&a means address of a
b *int means b is storing address which points to intger value
*b means value at the address stored in b
View copyfiles.diff
diff --git a/cmd/push.go b/cmd/push.go
index 636dc8c..07b031d 100644
--- a/cmd/push.go
+++ b/cmd/push.go
@@ -4,6 +4,7 @@ import (
"fmt"
"net/url"
"os"
+ "path/filepath"
@surajnarwade
surajnarwade / ListOfTalks.md
Last active Jul 9, 2018
List of My talks at meetups/conferences
View ListOfTalks.md
View retweetbot.py
import tweepy
import os
import ConfigParser
import sys
debug = True
# Create myconfig.ini file as per https://github.com/surajnarwade/pycon-india-scripts/blob/master/retweeting_script/config.ini
config_file = "myconfig.ini"
config_path = os.path.join(os.path.expanduser('~'), config_file)
View fresh minishift start
$ minishift start --show-libmachine-logs -v5
-- Checking if requested hypervisor 'kvm' is supported on this platform ... OK
-- Checking if KVM driver is installed ...
Driver is available at /usr/local/bin/docker-machine-driver-kvm ...
Checking driver binary is executable ... OK
-- Checking if Libvirt is installed ... OK
-- Checking if Libvirt default network is present ... OK
-- Checking if Libvirt default network is active ... OK
-- Checking the ISO URL ... OK
-- Starting profile 'minishift-1.9.0'
You can’t perform that action at this time.