kubectl apply -f https://gist.githubusercontent.com/tg123/16e2fcc4e97222c95c8143858c8a5faf/raw/8e01fb743d4f6563303b9fb163fcf9b63a6aa825/podping.yaml
kubectl get -n podping po
# check if any pod failure
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pwsh -Command { | |
& "C:\Program Files\Docker\Docker\Docker Desktop.exe" | |
Add-Type -Path "C:\Program Files\Docker\Docker\*.dll" -ErrorAction SilentlyContinue | Out-Null | |
while ($true) { | |
$instance = New-Object Docker.Core.GoBackend.GoBackendClient | |
$setting = $instance.GetSettingsAsync().Result |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"swagger": "2.0", | |
"info": { | |
"version": "v3", | |
"title": "Bot Framework Bot Protocol V3", | |
"description": "The Bot Connector REST API allows your bot to send and receive messages to channels configured in the\r\n[Bot Framework Developer Portal](https://dev.botframework.com). The Connector service uses industry-standard REST\r\nand JSON over HTTPS.\r\n\r\nClient libraries for this REST API are available. See below for a list.\r\n\r\nMany bots will use both the Bot Connector REST API and the associated [Bot State REST API](/en-us/restapi/state). The\r\nBot State REST API allows a bot to store and retrieve state associated with users and conversations.\r\n\r\nAuthentication for both the Bot Connector and Bot State REST APIs is accomplished with JWT Bearer tokens, and is\r\ndescribed in detail in the [Connector Authentication](/en-us/restapi/authentication) document.\r\n\r\n# Client Libraries for the Bot Connector REST API\r\n\r\n* [Bot Builder for C#](/en-us/csharp/builder/sdkreference/)\ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
import re | |
# http://stackoverflow.com/questions/4303492/how-can-i-simplify-this-conversion-from-underscore-to-camelcase-in-python | |
def underscore_to_camelcase(value): | |
def camelcase(): | |
yield str.lower | |
while True: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
t=$1 | |
if [ -z "$t" ];then | |
echo "usage: $0 ignoretype" | |
echo "example: $0 Java" | |
exit 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
for i in {`svn ls | grep /`,'.'}; do | |
svn ps svn:ignore $i -F .svnignore | |
done |
北京自动定饭脚本
节约粮食人人有则
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# origin from http://blog.fedora-fr.org/metal3d/post/typescript-to-gif | |
# modified by tgic to specified output file | |
# http://www.imagemagick.org/script/command-line-options.php#limit | |
CONVERTARG="-limit memory 32MiB -limit map 64MiB" | |
TIMING=$1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function coltable($db, $table){ | |
$stmt = $db->prepare("DESC $table"); | |
$stmt->execute(); | |
return array_map(function($v){ | |
return strtolower($v['Field']); | |
}, $stmt->fetchAll(PDO::FETCH_ASSOC)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from zipfile import ZipFile | |
from glob import glob | |
from itertools import groupby | |
from optparse import OptionParser | |
from fnmatch import fnmatchcase | |
class Printer: | |
def before(self): |