I hereby claim:
- I am monsterxx03 on github.
- I am monsterxx03 (https://keybase.io/monsterxx03) on keybase.
- I have a public key ASCvzuVyvGtUBllQW-u5m7Tz47GYN9OZpBPnvFzDZWs5ygo
To claim this, I am signing this object:
package main | |
import ( | |
"fmt" | |
"os" | |
"strconv" | |
"syscall" | |
"unsafe" | |
) |
apiVersion: v1 | |
kind: ConfigMap | |
metadata: | |
name: redis-config | |
data: | |
redis.conf: |- | |
bind 0.0.0.0 | |
port 6379 | |
protected-mode no | |
tcp-backlog 511 |
import time | |
import signal | |
class death_penalty_after(object): | |
def __init__(self, timeout): | |
self.timeout = timeout | |
def __enter__(self): | |
# register alarm siganl to handler | |
signal.signal(signal.SIGALRM, self.handle_death_penalty) |
package main | |
import ( | |
"context" | |
"flag" | |
"fmt" | |
"net" | |
"time" | |
) |
use std::io::{Read, Write, Result as IoResult}; | |
use std::net::{UdpSocket, TcpStream}; | |
const HOST: &str = "127.0.0.1"; | |
const PORT: u16 = 5354; | |
const UPSTREAM: &str = "114.114.114.114"; | |
const UPSTREAM_PORT: u16 = 53; | |
fn be_bytes_to_u16(b: &[u8;2]) -> u16 { | |
return ((b[0] as u16) << 8) | (b[1] as u16); |
#!/usr/bin/env bash | |
: ' | |
Simulate `kubectl rollout restart` commnad in 1.15. | |
' | |
set -o pipefail | |
set -o nounset | |
set -o errexit | |
usage() { |
import resource | |
import gc | |
from celery import Celery | |
app = Celery() | |
app.conf.update(BROKER_URL='redis://localhost:6379/1') | |
@app.task | |
def dummy(): |
import socket | |
import time | |
host = '127.0.0.1' | |
port = 80 | |
TOTAL_TIME = 0 | |
count = 10 | |
I hereby claim:
To claim this, I am signing this object:
import socket | |
from thread import start_new_thread | |
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) | |
s.bind(('127.0.0.1', 8001)) | |
s.listen(2) | |
print 'listening' | |
def clientthread(conn): |