Skip to content

Instantly share code, notes, and snippets.

View minho-comcom-ai's full-sized avatar

Minho Ryang minho-comcom-ai

View GitHub Profile
@minho-comcom-ai
minho-comcom-ai / locustfile.py
Created September 19, 2023 05:18 — forked from yamionp/locustfile.py
Websocket Locust Sample. locustfile and Echo/Chat Server
# -*- coding:utf-8 -*-
from __future__ import absolute_import
from __future__ import unicode_literals
from __future__ import print_function
import json
import uuid
import time
import gevent
#!/usr/bin/env bash
{ set +x; } 2>/dev/null
IFS=$'\n'
set "$@" $(find ~ -name ".*" ! -name ".CFUserTextEncoding" ! -type l -mindepth 1 -maxdepth 1) # dotfiles
set "$@" $(find ~ -name "Google *" -mindepth 1 -maxdepth 1) # Google Drive
set "$@" ~/git # store on github/etc :)
set "$@" ~/node_modules
set "$@" ~/Applications # install apps with brew cask
@minho-comcom-ai
minho-comcom-ai / save-load-docker-images.sh
Created November 29, 2020 09:23 — forked from mmrko/save-load-docker-images.sh
Script to (selectively) save/load multiple Docker images
#!/usr/bin/env bash
# Script to (selectively) save/load multiple Docker images to/from a directory.
# Run ./save-load-docker-images.sh for help.
set -e
directory=$PWD
filter=""
compress=0
@minho-comcom-ai
minho-comcom-ai / .config-readynas.diff
Created November 3, 2020 11:25 — forked from powareverb/.config-readynas.diff
Diff between ReadyNAS kernel config for 6.5.0 Beta 2 (linux-4.1.19-x86_64) and that which is required for base Docker setup
74,75c74
< CONFIG_POSIX_MQUEUE=y
< CONFIG_POSIX_MQUEUE_SYSCTL=y
---
> # CONFIG_POSIX_MQUEUE is not set
143,145c142,143
< CONFIG_BUILD_BIN2C=y
< CONFIG_IKCONFIG=m
< CONFIG_IKCONFIG_PROC=y
---
@minho-comcom-ai
minho-comcom-ai / delete-evicted-pods-all-namespaces.sh
Created October 19, 2020 07:01 — forked from svx/delete-evicted-pods-all-namespaces.sh
Delete evicted pods from all namespaces (also ImagePullBackOff and ErrImagePull)
#!/bin/sh
# based on https://gist.github.com/ipedrazas/9c622404fb41f2343a0db85b3821275d
# delete all evicted pods from all namespaces
kubectl get pods --all-namespaces | grep Evicted | awk '{print $2 " --namespace=" $1}' | xargs kubectl delete pod
# delete all containers in ImagePullBackOff state from all namespaces
kubectl get pods --all-namespaces | grep 'ImagePullBackOff' | awk '{print $2 " --namespace=" $1}' | xargs kubectl delete pod
# delete all containers in ImagePullBackOff or ErrImagePull or Evicted state from all namespaces
@minho-comcom-ai
minho-comcom-ai / git-deletebranches.sh
Created September 26, 2020 13:40 — forked from bxt/git-deletebranches.sh
Git Delete Merged Branches
#!/bin/bash
MAIN=${1:-development}
BRANCHES=$(git branch --merged $MAIN | grep -v -e 'master\|staging\|development\|\*')
echo Branches merged into $MAIN:
echo $BRANCHES
read -p "Delete these branches (y/n)? " answer
@minho-comcom-ai
minho-comcom-ai / bitbucket-highlight.user.js
Last active June 1, 2020 09:25 — forked from lephuongbg/bitbucket-highlight.user.js
Bitbucket Highlighter User Script
// ==UserScript==
// @name Bitbucket Highlighter
// @namespace https://github.com/lephuongbg
// @version 0.6
// @description Stop-gap solution for highlighting bitbucket pull request
// @author You
// @match https://bitbucket.org/*
// @grant GM_addStyle
// @grant GM_getResourceText
// @require https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.18.1/highlight.min.js