Skip to content

Instantly share code, notes, and snippets.

View elgalu's full-sized avatar

Leo Gallucci elgalu

View GitHub Profile
@elgalu
elgalu / .Xresources
Created April 13, 2023 16:55 — forked from taviso/.Xresources
XTerm Configuration
! XTerm resources
!
! Remember to run `xrdb < .Xresources` after changing anything.
!
! Tavis Ormandy <taviso@gmail.com>
! Set the default UI font (menus, toolbar, etc)
XTerm*XftFont: Segoe UI:size=10:antialias=true:style=Regular
! Color of UI Components

Both things have been introduced recently, and let you access even private ec2 instances

  1. Without VPN
  2. No open SSH port
  3. Authentication / Authorization is fully delegated to IAM
# Assumes valid AWS Credentials in ENV
@elgalu
elgalu / debug.sh
Created August 18, 2021 19:14 — forked from snstanton/debug.sh
Remote debugging k8s with pycharm
job_name=debug-`date +%Y%m%d%H%M%S`
kubectl create job ${job_name} --from cj/myveeva-v118273-app-maint
kubectl label pod -l job-name=${job_name} run=debug
kubectl wait --for condition=Ready pod -l job-name=${job_name}
pod_name=`kubectl get pods -l job-name=${job_name} -o jsonpath='{.items[0].metadata.name}'`
echo "installing tools"
kubectl exec ${pod_name} -- sh -c "apk -q update; apk -q add bash curl jq openssh rsync vim unzip postgresql-client; pip install -q ipython"
@elgalu
elgalu / process3dGraph.py
Last active April 23, 2023 14:27 — forked from jerilkuriakose/process3dGraph.py
This is a script which draws the amount of CPU used and memory usage of a process to a 3D graph. Python 3
#coding:utf-8
import psutil
from mpl_toolkits.mplot3d import Axes3D
import numpy as np
import matplotlib.pyplot as plt
import matplotlib.animation as animation
TIME_NUM = 90
FRAMES = 360
@elgalu
elgalu / ...README.md
Created July 21, 2017 14:30 — forked from schlomo/...README.md
Demo for UI testing with selenium based on Zalenium, see http://blog.schlomo.schapiro.org/2017/07/web-ui-testing-made-easy-with-zalenium.html for details

Intro

The plan is to create a pair of executables (ngrok and ngrokd) that are connected with a self-signed SSL cert. Since the client and server executables are paired, you won't be able to use any other ngrok to connect to this ngrokd, and vice versa.

DNS

Add two DNS records: one for the base domain and one for the wildcard domain. For example, if your base domain is domain.com, you'll need a record for that and for *.domain.com.

Different Operating Systems

@elgalu
elgalu / steps.md
Last active January 4, 2016 12:19 — forked from carlosmcevilly/gist:2221249
Fix commit author of last commit
  1. Fix your email address in git config
git config user.name "Your Name"
git config user.email "your@address.com"
git submodule foreach --recursive 'git config user.name "Your Name" && git config user.email "your@address.com"'
  1. Rebase