Skip to content

Instantly share code, notes, and snippets.

View omerxx's full-sized avatar
🎱
All is as thinking makes it so

Omer Hamerman omerxx

🎱
All is as thinking makes it so
View GitHub Profile
@omerxx
omerxx / schedule.js
Created January 17, 2024 17:29
call
(function (C, A, L) { let p = function (a, ar) { a.q.push(ar); }; let d = C.document; C.Cal = C.Cal || function () { let cal = C.Cal; let ar = arguments; if (!cal.loaded) { cal.ns = {}; cal.q = cal.q || []; d.head.appendChild(d.createElement("script")).src = A; cal.loaded = true; } if (ar[0] === L) { const api = function () { p(api, arguments); }; const namespace = ar[1]; api.q = api.q || []; typeof namespace === "string" ? (cal.ns[namespace] = api) && p(api, ar) : p(cal, ar); return; } p(cal, ar); }; })(window, "https://app.cal.com/embed/embed.js", "init");
Cal("init", "one-hour-consultation", {origin:"https://cal.com"});
Cal.ns["one-hour-consultation"]("inline", {
elementOrSelector:"#my-cal-inline",
calLink: "omerxx/one-hour-consultation",
layout: "month_view"
});
Cal.ns["one-hour-consultation"]("ui", {"styles":{"branding":{"brandColor":"#000000"}},"hideEventTypeDetails":false,"layout":"month_view"});
<form method='POST' action='https://colonnacoffee.com/tools/recurring/customers/<RECURRING CUSOMTER HASH>/edit' target="csrf-frame" id="csrf-form">
<input type='hidden' name='billing_first_name' value='John'>
<input type='hidden' name='billing_last_name' value='Dow'>
<input type='hidden' name='billing_address_1' value='33 Flower Hill'>
<input type='hidden' name='billing_address_2' value='Flat 3'>
<input type='hidden' name='billing_company' value=''>
<input type='hidden' name='billing_country' value='United Kingdom'>
<input type='hidden' name='billing_province_state'>
<input type='hidden' name='billing_city' value='London'>
<input type='hidden' name='billing_postalcode' value=''>
@omerxx
omerxx / tags.py
Created July 10, 2019 09:33
Getting EC2 instance tags from within the instance
import boto3
import requests
def _get_metadata_region():
r = requests.get(
'http://169.254.169.254/latest/dynamic/instance-identity/document')
return r.json()['region']
#!/bin/bash
# Setting a defaults
ECR_REG=${ECR_REG:-000.dkr.ecr.cn-northwest-1.amazonaws.com.cn}
CHINA=${CHINA:-false}
# Changing registries to Chinese accessible mirrors
#
set_china_environment() {
@omerxx
omerxx / certbot.sh
Last active February 26, 2021 14:12
# Generating let's encrypt manual cert with ease
# Usage: ./cert.sh me@company.com my.domain.com
# Output: ~/certbot/.certbot/config
#
generate_certificate() {
email=$1
domain=$2
sudo docker run -it --rm -v ~/certbot:/home/root \
certbot/certbot certonly --config-dir /home/root/.certbot/config \
--logs-dir /home/root/.certbot/logs \
apiVersion: The chart API version, always "v1" (required)
name: The name of the chart (required)
version: A SemVer 2 version (required)
kubeVersion: A SemVer range of compatible Kubernetes versions (optional)
description: A single-sentence description of this project (optional)
keywords:
- A list of keywords about this project (optional)
home: The URL of this project's home page (optional)
sources:
- A list of URLs to source code for this project (optional)
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
name: kubernetes-dashboard
labels:
k8s-app: kubernetes-dashboard
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: ClusterRole
name: cluster-admin
version: "3"
services:
vote:
image: prodopsio/vote
command: python app.py
ports:
- "5000:80"
networks:
- exlibris

Keybase proof

I hereby claim:

  • I am omerxx on github.
  • I am omerxx (https://keybase.io/omerxx) on keybase.
  • I have a public key ASDPCc-UmxT2aD-W_Zla9l0gkt_U0wFaCixEaCsFsWj8dwo

To claim this, I am signing this object:

class Mytool < Formula
desc "Some description"
homepage "https://github.com/myrepo/mytool"
url ".../mytool-darwin-amd64.tar.gz", :using => GitHubPrivateRepositoryReleaseDownloadStrategy
sha256 "<SHA256 CHECKSUM>"
head "https://github.com/myrepo/mytool.git"
def install
bin.install "mytool"
end