Skip to content

Instantly share code, notes, and snippets.

"""
Launch a process alongside with the caller.
Supply input to that process and read outputs,
rinse and repeat.
Sample usage:
with ProcessSession(['.venv/bin/python3', '-m', 'simultons']) as session:
cmd = 'set debug true'
while not session.wait(0.1):
stdout, stderr = session.consume_outputs(cmd)
What are the main categories into which Kubernetes monitoring is divided?
- infra
- orchestration & control
- application
Which of the following are potential trouble indicators for pod conditions that the K8s Analyzer examines?
- pod status failed
- pod status pending
- pod status unknown
@asokolsky
asokolsky / urldecode
Created June 5, 2024 21:30
one-liner to do url-decoding
echo -n "%21%20" | python3 -c "import sys; from urllib.parse import unquote; print(unquote(sys.stdin.read()));"