Skip to content

Instantly share code, notes, and snippets.

View JokerQyou's full-sized avatar

Joker_ JokerQyou

View GitHub Profile
@JokerQyou
JokerQyou / win_subprocess.py
Last active April 19, 2018 02:18 — forked from vaab/win_subprocess.py
Fixing python 2.7 windows unicode issue with ``subprocess.Popen``.
# coding: utf-8
# This patched `Popen` class
# adds support for Unicode commandline on Windows platform.
# issue: https://bugs.python.org/issue19264
import os
import ctypes
import subprocess
import _subprocess
from ctypes import (
// --- Compiling ---
$ wget http://download.redis.io/releases/redis-2.8.3.tar.gz
$ tar xzvf redis-2.8.3.tar.gz
$ cd redis-2.8.3
$ make
$ make install
// --- or using yum ---
$ rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
$ rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
@JokerQyou
JokerQyou / cloud-init-docker.yaml&env=plain&abbr=cloud-init
Last active April 22, 2020 02:10
Cloud-init user data to install some fundamental components
#cloud-config
runcmd:
- curl -fsSL https://get.docker.com | sh
- curl -L "https://github.com/docker/compose/releases/download/1.24.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
- chmod +x /usr/local/bin/docker-compose
- ln -s /usr/local/bin/docker-compose /usr/local/bin/dc
- apt-get install -y zsh git
groups: