Skip to content

Instantly share code, notes, and snippets.

View kairen's full-sized avatar
😇
I may be slow to respond.

Kyle Bai kairen

😇
I may be slow to respond.
View GitHub Profile
@ikurni
ikurni / force-mcp-ocp-update
Created October 5, 2020 14:43
How to force openshift MCP to update machine config
### Create file called machine-config-daemon-force in /run ###
ssh core@hostname.local sudo touch /run/machine-config-daemon-force
### Edit node annotations ###
oc edit node <node-name>
### Check Annotations, change like below sample ###
machineconfiguration.openshift.io/currentConfig: rendered-worker-ab4a1e7216bf3da2a5203f09c871b456
machineconfiguration.openshift.io/desiredConfig: rendered-worker-ab4a1e7216bf3da2a5203f09c871b456
machineconfiguration.openshift.io/reason: ""
@yuanying
yuanying / secure-k8s.txt
Created October 8, 2015 05:10
Create secure k8s by Magnum
(venv)[yuanying@Soloist] ~/Projects/OpenStack/python-magnumclient/.tox
 openssl genrsa -out /client.key 4096
Generating RSA private key, 512 bit long modulus
.....++++++++++++
...............++++++++++++
e is 65537 (0x10001)
(venv)[yuanying@Soloist] ~/Projects/OpenStack/python-magnumclient/.tox
 openssl req -new -days 1000 \
-key "client.key" \
-out "client.csr" \
#!/usr/bin/env python3
#
# Dumb script to dump (some) of bcache status
# Copyright 2013 Darrick J. Wong. All rights reserved.
#
# This file is part of Bcache. Bcache is free software: you can
# redistribute it and/or modify it under the terms of the GNU General Public
# License as published by the Free Software Foundation, version 2.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
@Globegitter
Globegitter / nginx-latest.sh
Last active May 7, 2022 18:19
Install the latest nginx from source for Ubuntu 14.04
# Automatically instal the latest nginx
wget -O - http://nginx.org/keys/nginx_signing.key | sudo apt-key add -
#Make a backup copy of your current sources.list file
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
#Now copy the following repositories to the end of ` /etc/apt/sources.list`
echo "deb http://nginx.org/packages/mainline/ubuntu/ trusty nginx" | sudo tee -a /etc/apt/sources.list
echo "deb-src http://nginx.org/packages/mainline/ubuntu/ trusty nginx" | sudo tee -a /etc/apt/sources.list