Skip to content

Instantly share code, notes, and snippets.

@haproxytechblog
haproxytechblog / blog20210114-01.sh
Last active May 23, 2021 11:17
Announcing HAProxy Data Plane API 2.2
$ curl -u dataplaneapi:mypassword \
-H 'Content-Type: application/json' \
-d '{
"name": "consul-server",
"address": "consul.local",
"port": 8500,
"enabled": true,
"retry_timeout": 10
}' http://localhost:5555/v2/service_discovery/consul
@Overbryd
Overbryd / best-brownies-of-your-life.md
Last active February 28, 2019 12:30
These are the best brownies of your life

Best brownies of your life

This is a really great brownie recipe, originally taken from this BuzzFeed article. Here, have my version of it, without all the fuzz and ads.

Ingredients

  • 1 1/4 Cups butter
  • 225g chocolate 60-70%
  • 3/4 Cups dark processed cocoa powder
  • 1 Tbsp espresso powder
@thetechnick
thetechnick / ignition.json
Last active June 22, 2023 17:46
Hetzner Cloud terraform coreos install
{
"ignition": {
"version": "2.0.0",
"config": {}
},
"storage": {
},
"systemd": {},
"networkd": {},
"passwd": {
@bufadu
bufadu / howto_bgp_ecmp_load_balancing.md
Last active March 2, 2024 19:13
BGP ECMP Load Balancer

How to build a load balancer with BGP and ECMP using VyOS

According to this cloudflare blog article "Load Balancing without Load Balancers", we can build a rock-solid load balancer only using a router. All the magic comes from BGP and Equal-Cost Multi-Path routing.

In this howto, I will use bird as BGP router on linux instance (ie. servers).

Test environment

I use GNS3 with this architecture :

architecture

@deviantony
deviantony / README.md
Last active September 4, 2024 02:41
Portainer HTTP API by example

DEPRECATION NOTICE

This gist is now deprecated in favor of our official documentation: https://documentation.portainer.io/api/api-examples/ which contains up to date examples!

THE FOLLOWING DOCUMENTATION IS DEPRECATED

Please refer to the link above to get access to our updated API documentation and examples.

@themartorana
themartorana / dogstatsd
Created May 5, 2016 16:48
dogstatsd rc.d file
#!/bin/sh
# $FreeBSD$
# PROVIDE: dogstatsd
# KEYWORD: shutdown
. /etc/rc.subr
name=dogstatsd
rcvar=${name}_enable
@mpasternacki
mpasternacki / freebsd_on_mbp.md
Created January 23, 2015 17:12
FreeBSD on a MacBook Pro

FreeBSD on a MacBook Pro

Since 2008 or 2009 I work on Apple hardware and OS: back then I grew tired of Linux desktop (which is going to be MASSIVE NEXT YEAR, at least since 2001), and switched to something that Just Works. Six years later, it less and less Just Works, started turning into spyware and nagware, and doesn't need much less maintenance than Linux desktop — at least for my work, which is system administration and software development, probably it is better for the mythical End User person. Work needed to get software I need running is not less obscure than work I'd need to do on Linux or othe Unix-like system. I am finding myself turning away from GUI programs that I used to appreciate, and most of the time I use OSX to just run a terminal, Firefox, and Emacs. GUI that used to be nice and unintrusive, got annoying. Either I came full circle in the last 15 years of my computer usage, or the OSX experience degraded in last 5 years. Again, this is from a sysadmin/developer ki

@mlafeldt
mlafeldt / recipe.rb
Created January 9, 2015 10:47
Package Go tools with fpm-cookery (automatically uses godep dependencies if present)
class ChefRunner < FPM::Cookery::Recipe
GOPACKAGE = "github.com/mlafeldt/chef-runner"
name "chef-runner"
version "0.8.0"
revision 1
source "https://#{GOPACKAGE}/archive/v#{version}.tar.gz"
sha256 "a7de23f989f8353ecf838b551a8ceff09b83c8aeff2553b2c31d57615f8fcc53"
description "The fastest way to run Chef cookbooks"
@rhenning
rhenning / opsworks_blue_green_deploy_test_long_version
Created February 13, 2014 01:11
AWS OpsWorks full-stack blue/green deploy test
$ aws opsworks describe-stacks
{
"Stacks": [
{
"ServiceRoleArn": "arn:aws:iam::047170177871:role/aws-opsworks-service-role",
"StackId": "575e1389-1df3-427d-99d3-d60f89a41442",
"DefaultRootDeviceType": "ebs",
"Name": "rhenning_test",
"ConfigurationManager": {
"Version": "11.4",
@fh
fh / nginx.conf
Last active December 28, 2015 04:48
My Crypto Configs
listen 443 ssl;
ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers kECDH:HIGH:!aNULL:!MEDIUM:!LOW:!NULL:!SSLv2:!ADH@STRENGTH;
ssl_prefer_server_ciphers on;
ssl_certificate /path/to/file.crt;
ssl_certificate_key /path/to/file.key;
#to enable forward secrecy. Generate the file using
#openssl dhparam -outform PEM -out dh.pem 1024
ssl_dhparam /path/to/dh.pem;