Skip to content

Instantly share code, notes, and snippets.

View OrkhanAlikhanov's full-sized avatar
Be mindful of your Creator! We all will die soon...

Orkhan Alikhanov OrkhanAlikhanov

Be mindful of your Creator! We all will die soon...
View GitHub Profile
jgeewax / configure-mailgun
Created December 7, 2015 17:59
Script to configure Postfix for Mailgun
# Configuration for the script
function confirm () {
read -r -p "${1:-Are you sure? [Y/n]} " response
if [[ $response == "" || $response == "y" || $response == "Y" ]]; then
echo 0;
zacwest / ios-font-sizes.swift
Last active June 17, 2024 01:38
iOS default font sizes - also available on
let styles: [UIFont.TextStyle] = [
// iOS 17
.extraLargeTitle, .extraLargeTitle2,
// iOS 11
// iOS 9
.title1, .title2, .title3, .callout,
// iOS 7
.headline, .subheadline, .body, .footnote, .caption1, .caption2,
mondain / public-stun-list.txt
Last active June 17, 2024 19:44
Public STUN server list
kinichiro / 1_Hello_libtls
Last active October 2, 2023 14:56
Hello libtls - libressl libtls API sample program
Hello libtls - libressl libtls API sample program
philipstanislaus / sane-caching.nginx.conf
Last active June 19, 2024 03:05
Sample Nginx config with sane caching settings for modern web development
# Sample Nginx config with sane caching settings for modern web development
# Motivation:
# Modern web development often happens with developer tools open, e. g. the Chrome Dev Tools.
# These tools automatically deactivate all sorts of caching for you, so you always have a fresh
# and juicy version of your assets available.
# At some point, however, you want to show your work to testers, your boss or your client.
# After you implemented and deployed their feedback, they reload the testing page – and report
# the exact same issues as before! What happened? Of course, they did not have developer tools
# open, and of course, they did not empty their caches before navigating to your site.
ericclemmons /
Last active April 24, 2024 18:09
HTML5 <details> in GitHub

Using <details> in GitHub

Suppose you're opening an issue and there's a lot noisey logs that may be useful.

Rather than wrecking readability, wrap it in a <details> tag!

 Summary Goes Here
stefanbuck /
Last active November 26, 2023 12:40
Script to upload a release asset using the GitHub API v3.
#!/usr/bin/env bash
# Author: Stefan Buck
# License: MIT
# This script accepts the following parameters:
# * owner
roylee0704 /
Created December 9, 2016 08:24
how to grep docker log
docker logs nginx 2>&1 | grep "127."
# ref:
procrastinatio /
Created October 25, 2017 06:04
Rate limiting with HAproxy


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])

ccwasden / WithPopover.swift
Created February 5, 2020 13:39
Custom size popover in iOS SwiftUI
// -- Usage
struct Content: View {
@State var open = false
@State var popoverSize = CGSize(width: 300, height: 300)
var body: some View {
showPopover: $open,
popoverSize: popoverSize,