Skip to content

Instantly share code, notes, and snippets.

View vvucetic's full-sized avatar

Vedran Vučetić vvucetic

View GitHub Profile
@thimslugga
thimslugga / 01_setup-docker-al2023.md
Last active February 6, 2026 21:44
Setup Docker on Amazon Linux 2023

Setup Docker on Amazon Linux 2023

The following guide is for setting up Docker with docker-compose v2 on Amazon Linux 2023. The steps are intendend for AL2023 on EC2 but should mostly work for the AL2023 VMs running on other hypervisors.

Install and configure Docker on Amazon Linux 2023

Install Base OS Packages

Install the following packages, which are good to have installed:

@bobvanderlinden
bobvanderlinden / experiment.lua
Created October 30, 2019 16:40
HTTP path pattern matching for HAProxy using LUA
local function matches(input, pattern)
local index = 1
return function()
local match = input:match(pattern, index)
if match then
index = index + match:len() + 1
return match
else
return nil
end
@haproxytechblog
haproxytechblog / blog20181128-01.cfg
Created April 24, 2019 19:57
Dynamic Configuration with the HAProxy Runtime API
global
stats socket ipv4@127.0.0.1:9999 level admin
stats socket /var/run/hapee-lb.sock mode 666 level admin
stats timeout 2m
@procrastinatio
procrastinatio / haproxy_rate_limiting.md
Created October 25, 2017 06:04
Rate limiting with HAproxy

Introduction

So HAProxy is primalery a load balancer an proxy for TCP and HTTP. But it may act as a traffic regulator. It may also be used as a protection against DDoS and service abuse, by maintening a wide variety of statistics (IP, URL, cookie) and when abuse is happening, action as denying, redirecting to other backend may undertaken ([haproxy ddos config], [haproxy ddos])

@cherti
cherti / alert.sh
Created December 9, 2016 13:47
send a dummy alert to prometheus-alertmanager
#!/bin/bash
name=$RANDOM
url='http://localhost:9093/api/v1/alerts'
echo "firing up alert $name"
# change url o
curl -XPOST $url -d "[{
\"status\": \"firing\",
@richarddun
richarddun / gist:1bb11d32cafc394efbcb8f4a8b6cb130
Last active January 30, 2025 19:33
scapy script to send http requests
#!/usr/bin/env python
"""
Script to open TCP connection and send 1 HTTP GET request containing
a specific string, and header
Usage:
./http.py <IP_of_target>
There is only one mandatory argument, which is the target IP address.
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active February 19, 2026 17:19
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k