Skip to content

Instantly share code, notes, and snippets.

View edib's full-sized avatar

ibrahim edib kokdemir edib

View GitHub Profile
# kablotv mac address engelleme
# notlar
# önceden kayıtlı tek mac adresi için kullanılmıştır.
# kullanımı
# python3 macKontrol.py [0|2]
from selenium import webdriver
import sys
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"
sudo mv kubectl /usr/bin/
sudo chmod +x /usr/bin/kubectl
mkdir .kube
sudo cp /etc/kubernetes/admin.conf .kube/config
kubectl get node
@edib
edib / kubectl.md
Created September 25, 2023 12:33

Some Importants

Basic Interactions:

    kubectl version: Display the client and server versions.

    kubectl help: Display help documentation.

Cluster Information:
@edib
edib / pg-auditing.sql
Last active September 15, 2023 15:32
-- şema içerisinde audit_logs tablosu
CREATE TABLE audit_logs (
id serial PRIMARY KEY,
operation VARCHAR(50) NOT NULL,
table_name VARCHAR(255) NOT NULL,
old_data TEXT,
new_data TEXT,
changed_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
changed_by VARCHAR(255)
);
@edib
edib / nginx.conf
Created April 2, 2018 21:54
moodle subdirectory inside a wordpress installation
server {
listen 80 default_server;
listen [::]:80 default_server;
root /var/www/wordpress;
index index.php index.html index.htm index.nginx-debian.html;
server_name _;
image: maven:3.9.1-eclipse-temurin-17-alpine
cache:
paths:
- .m2/repository
key: "$CI_BUILD_REF_NAME"
variables:
MAVEN_CLI_OPTS: "-s .m2/settings.xml --batch-mode"
MAVEN_OPTS: "-Dmaven.repo.local=$CI_PROJECT_DIR/.m2/repository -Dmaven.artifact.threads=50"
@edib
edib / pglogical
Last active April 26, 2023 09:50 — forked from ratnakri/pglogical
short tutorial to setup replication using pglogical
Edit /var/lib/postgres/data/postgresql.conf:
# change IP on subscriber
listen_addresses = '*'
wal_level = logical
shared_preload_libraries = 'pglogical'
max_worker_processes = 16
max_wal_senders = 16
max_replication_slots = 16
track_commit_timestamp = on
@edib
edib / firefox-pw.desktop
Last active April 8, 2023 14:51
~/.local/share/applications/firefox-ps.desktop
[Desktop Entry]
Name=Firefox-PW
Comment=Firefox for Proxyied Web
Exec=env /snap/bin/firefox -p "my-another-profile"
Icon=/snap/firefox/2487/default256.png
Terminal=false
Type=Application
StartupNotify=true
Keywords=Internet;WWW;Browser;Web;Explorer
GenericName=Web Browser for Proxyied Web
# ZSH Theme - Preview: https://gyazo.com/8becc8a7ed5ab54a0262a470555c3eed.png
EMOJI=(💩 🐦 🚀 🐞 🎨 🍕 🐭 👽 ☕️ 🔬 💀 🐷 🐼 🐶 🐸 🐧 🐳 🍔 🍣 🍻 🔮 💰 💎 💾 💜 🍪 🌞 🌍 🐌 🐓 🍄 😀 😹 🌾 ♂️ 🐵 🦎 🦖 🦕 🐙 🦑 🦐 🦞 🦀 🐊 🐅 🎄 🌲 🌳 🌴 🌱 🌿 ☘️ 🎍 🎋 🍃 🍂 🍁)
function random_emoji {
echo -n "$EMOJI[$RANDOM%$#EMOJI+1]"
}
# ...
apiVersion: argoproj.io/v1alpha1
kind: Workflow
metadata:
name: build-and-push
spec:
entrypoint: build-and-push
templates:
- name: build-and-push
steps:
- - name: checkout