Let's look at some basic kubectl output options.
Our intention is to list nodes (with their AWS InstanceId) and Pods (sorted by node).
We can start with:
kubectl get no
#!/usr/bin/env python | |
# coding=utf-8 | |
"""Client that demonstrates processing pipeline.""" | |
import asyncio | |
from functools import partial | |
import logging | |
logging.basicConfig(level='DEBUG') |
let g:python_host_skip_check = 1 | |
let g:python3_host_skip_check = 1 | |
let g:python_host_prog = '/usr/local/bin/python2' | |
let g:python3_host_prog = '/usr/local/bin/python3' | |
let g:EditorConfig_exec_path = '/usr/local/bin/editorconfig' | |
let g:EditorConfig_core_mode = 'external_command' | |
" Deoplete |
development: | |
adapter: mysql2 | |
encoding: utf8 | |
database: my_database | |
username: root | |
password: | |
apt: | |
- somepackage | |
- anotherpackage |
# localhost | |
sudo tshark -i lo | |
# or add loopback interface | |
sudo ifconfig lo0 alias 127.0.0.0 up | |
sudo tshark -i lo0 | |
# eth0 | |
sudo tshark -i eth0 -f 'port 80 or 443' -R 'http.host matches ".*?youtube\.com.*"' -S -V -l -T fields -e ip.src -e ip.src_host -e ip.dst -e ip.dst_host -e http.accept -e http.accept_encoding -e http.accept_language -e http.authbasic -e http.authorization -e http.cache_control -e http.connection -e http.content_encoding -e http.content_length -e http.content_length_header -e http.content_type -e http.cookie -e http.date -e http.host -e http.last_modified -e http.location -e http.notification -e http.proxy_authenticate -e http.proxy_authorization -e http.proxy_connect_host -e http.proxy_connect_port -e http.referer -e http.request -e http.request.full_uri -e http.request.method -e http.request.uri -e http.request.version -e http.response -e http.response.code -e http.response.phrase -e http.sec_websocket_accept -e http.sec_websocket_extensions -e http.sec_websocket_key -e http.sec_websock |
days_default = {'월':0, '화':1, '수':2, '목':3, '금':4, '토':5, '일':6} | |
# input: 0, 1, 2, 4, 6 | |
# output: 0~2, 4, 6 | |
reverse= dict((v, k) for k, v in days_default.items()) | |
def collapse_weekdays(days): | |
days = list(map(lambda k: days_default.get(k), days)) | |
shift = lambda n, k: (n + 1 < k and days[n + 1] - days[n] == 1) and shift(n + 1, k) or n |
Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...
// see: https://github.com/chadoe/docker-cleanup-volumes
$ docker volume rm $(docker volume ls -qf dangling=true)
$ docker volume ls -qf dangling=true | xargs -r docker volume rm
FILE SPACING: | |
# double space a file | |
sed G | |
# double space a file which already has blank lines in it. Output file | |
# should contain no more than one blank line between lines of text. | |
sed '/^$/d;G' |
Ethereum is a decentralized platform that runs smart contracts: applications that run exactly as programmed without any possibility of downtime, censorship, fraud or third party interference.
This is a step-by-step guide, how to setup private Ethereum network.
We’ll set up a network and create two simple JSON-RPC clients in order to communicate with our Ethereum nodes.
def sha256_encode(secret, password): | |
""" | |
Spring Security 모듈의 StandardPasswordEncoder encode() 함수를 구현 | |
:param secret: | |
:param password: | |
:return: | |
""" | |
salt_key_length = 8 | |
max_hash_rounds = 1024 |