Skip to content

Instantly share code, notes, and snippets.

View xiongjia's full-sized avatar
🤿
Focusing

Xiong-Jia.Le xiongjia

🤿
Focusing
View GitHub Profile
@nginx-gists
nginx-gists / Dockerfile
Last active September 9, 2023 15:37
Our Roadmap for QUIC and HTTP3 Support in NGINX
# Builds NGINX from the QUIC+HTTP/3 development branch
# - Based on the official NGINX docker image, including all modules built by default
# - OpenSSL replaced with LibreSSL to support QUIC's TLS requirements (statically linked)
#
# docker build --no-cache -t nginx:quic .
# docker run -d -p 443:443 -p 443:443/udp nginx:quic
#
# Note that a suitable configuration file and TLS certificates are required for testing!
# See <https://quic.nginx.org/readme.html> for more info
@welshstew
welshstew / SomescriptsApplication.groovy
Last active August 4, 2022 01:42
Building a spring boot fat jar with gradle and red hat fuse
package com.codergists.somescripts
import org.springframework.boot.SpringApplication
import org.apache.camel.builder.RouteBuilder
import org.springframework.boot.autoconfigure.SpringBootApplication
import org.apache.camel.component.servlet.CamelHttpTransportServlet
import org.springframework.boot.web.servlet.ServletRegistrationBean
import org.springframework.context.annotation.Bean
import org.apache.camel.model.rest.RestBindingMode
import org.apache.camel.LoggingLevel
@jjeffery
jjeffery / golang-dev-env-windows.md
Last active September 9, 2022 02:56
Preparing a Go development environment on a Windows PC

Installing a Go development environment on a Windows PC

NOTE: A lot of these instructions change with Go 1.11 and later. These instructions are for Go 1.10.

Prerequisites

Install the following programs.

  • Git bash (https://git-scm.com/download/win) Git is necessary for the go get command, and using the git bash command line works well with the go dev environment.
@mcspring
mcspring / Makefile
Created June 26, 2018 07:36
Static build of nginx with custom openssl, pcre and zlib
# Author: Eric Pruitt (http://www.codevat.com)
# License: 2-Clause BSD (http://opensource.org/licenses/BSD-2-Clause)
# Description: This Makefile is designed to create a statically linked nginx
# binary without any dependencies on the host system's version of glibc.
NGINX_VERSION=1.15.0
OPENSSL_VERSION=1.0.2o
PCRE_VERSION=8.42
ZLIB_VERSION=1.2.11
@schnell18
schnell18 / pip_mirror.sh
Last active January 19, 2024 10:53
setup pip mirror in China
mkdir ~/.pip
cat <<EOF > ~/.pip/pip.conf
[global]
trusted-host = mirrors.aliyun.com
index-url = http://mirrors.aliyun.com/pypi/simple
EOF
@boneskull
boneskull / README.md
Last active April 10, 2024 12:47
example of how to debug mocha v4 if hanging

Here's an example of how to debug Mocha v4 if it hangs.

Ensure you're using a Node.js 8 or newer (or any version with async_hooks support).

If you run your test, you'll notice it hangs:

$ mocha test.js
@kevinkreiser
kevinkreiser / worker_pool.py
Created August 31, 2017 15:15
Work Queue Thread Pool Example in Python
#!/usr/bin/env python
#this is mostly from:
#http://code.activestate.com/recipes/577187-python-thread-pool/
from Queue import Queue
from threading import Thread, Event
from sys import stdout, stderr
from time import sleep