Skip to content

Instantly share code, notes, and snippets.

View concatime's full-sized avatar

Issam Maghni concatime

  • Montréal, QC.
View GitHub Profile
#!/bin/sh
#Adding sources for NodeJS
cat <<EOT | sudo cp /dev/stdin /etc/apt/sources.list.d/nodesource.list
deb https://deb.nodesource.com/node_7.x yakkety main
deb-src https://deb.nodesource.com/node_7.x yakkety main
EOT
#Adding NodeJS's public key
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | sudo apt-key add
@concatime
concatime / .ngx_wizard.md
Last active April 19, 2018 21:42
[DEPRECATED] ngx_wizard.sh

DEPRECATED, evolved to this.

@concatime
concatime / -.md
Last active September 27, 2018 02:12
Toolbox for compilation!

Global dependencies: git cc c++ ld unzip

cmake ninja autotools(m4 autoconf[autoreconf] automake[aclocal])

Package Repology Minimal dependencies (optional)
NGiИX jemalloc pcre libressl zlib
cURL c-ares mbedtls nghttp2 (libssh2)
LibreSSL
mbedTLS zlib
# Conf
RUST=1.21.0
LUAJIT=2.1.0-beta3
CC=gcc
CFLAGS+=-pipe
MAKEFLAGS+=-j`nproc`
export CFLAGS MAKEFLAGS
# Exit if any exit 1
set -e
@concatime
concatime / .sh
Last active July 12, 2018 13:27
Pretty Useless Bleeding Edge OpenResty — Latest NGiИX, OpenSSL, LuaJIT & PCRE + LuaRocks & Lapis webframework » bash <(curl -s https://gist.githubusercontent.com/concatime/04127487894c522cb240e0f95bdd92e7/raw)
OPENSSL=openssl-1.0.2o
OPENRESTY=openresty-1.13.6.2
LUAROCKS=2.4.4
LUAJIT=LuaJIT-2.1.0-beta3
NGX=nginx-1.15.1
PCRE=8.42
# OpenSSL 1.1 & PCRE2 (10.0) aren't _yet_ supported.
# https://github.com/openresty/lua-nginx-module/issues/852
# https://stackoverflow.com/a/34795745
#
# The script will ask you some questions when rendering the private key.
#
OPENSSL=openssl-1.1.0g
CFLAGS+=-pipe
MAKEFLAGS+=-j`nproc`
CPATH=/opt/openssl/include
LIBRARY_PATH=/opt/openssl/lib
export CFLAGS MAKEFLAGS LIBRARY_PATH CPATH
set -e
@concatime
concatime / .md
Last active April 19, 2018 21:41
ngx_wizard

[DEPRECATED] Take a look at H2O webserver.

NGiИX WIZARD

Features of ngx_wizard:

  • Optimized nginx ;
  • Tweaked settings ;
  • Bleading Edge ;
  • Self Contained Package ;
  • Compiled from scratch ;
  • Based on shared libraries ;

H2Ø WIZARD

Features of h2o_wizard:

  • Bleading Edge ;
  • Compiled from scratch;
  • Based on static libraries ;
  • LibreSSL as SSL library ;

This script is provided AS IS & comes with ABSOLUTELY NO WARRANTY!

Instructions

@concatime
concatime / google_encrypted.xml
Last active August 20, 2017 17:13
Google Encrypted for Firefox Raw
<OpenSearchDescription xmlns='http://a9.com/-/spec/opensearch/1.1/' xmlns:moz='http://www.mozilla.org/2006/browser/search/'>
<ShortName>Google Encrypted</ShortName>
<Description>Enhanced Google search</Description>
<InputEncoding>UTF-8</InputEncoding>
<Image width='16' height='16'>
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGAAAABgCAYAAADimHc4AAAHqklEQVR4Ae2dVXgbSRaFe5lelnnfluFlmCnMzMzMzMwMCjPMKOsxM7MVh5kTc0AMJePDWd+dT172WupuVXVc+b4zwZF0/9N1763qVpUS+AHgSzU1NWOrq6vPN8rr9/shihhj6v8fziKmxJYYE2sACon+Q/pp419mGAi4oQ0h1sQ8YMCXeMMnOPzfk4sJX1Iah8Q4AYNvFYZQOlIoL/EPtHWaQOwVfgVXitgrrfVqFyUGRcLnG4uix4cVH744cSl8A5NSZLrhG7Mi4fONXZHwuZjAvwZIiW+ANECmHf3ZKKLDZ3YbvJZ8uE8cgmP5PDhmjoN9zADY+nWCtdN7sLZ/C7Yen8A2oDMc4weD/o3rwE54kuPAykuFN0EREb7v3h249u+EfXR/WNu+AWub10OWbXB3OLeuhfeihb8JItcAZrXCE3EW9olDCZwuolFCI4lZX8gi3CS3C+4zx2Dr2YYghUddPoDLtI1M528At9TDGDyxn9NVSVC4yNa7HdxRZq6piIsBvopyOGZNIAhCyLloBqUl/gaEA74nJwO2Xm0pcKFkG9IDvlvXw26CEk74LtN2ClZYUVvriY/SwwTORZgxuDavpiDFV8d34Htw7yXqgnw+ONcsNgx8b17Wy9WGOlfOl/B5GeA6fkDCD9YArYo
GOVER=1.9.1
curl https://storage.googleapis.com/golang/go$GOVER.linux-amd64.tar.gz --silent | sudo tar xzC /usr/local
cd
echo . \~/.goenv >> .bashrc
cat > .goenv <<EOT
for i in /usr/local/go ~/go
do PATH+=:\$i/bin
done
export PATH
GOCODE=\$(go env GOPATH)