This file contains hidden or 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
$ diskutil eraseDisk JHFS+ SecretDisk GPT /dev/disk3 | |
Started erase on disk3 | |
Unmounting disk | |
Creating the partition map | |
Waiting for partitions to activate | |
Formatting disk3s2 as Mac OS Extended (Journaled) with name SecretDisk | |
Initialized /dev/rdisk3s2 as a 931 GB case-insensitive HFS Plus volume with a 81920k journal | |
Mounting disk | |
Finished erase on disk3 |
This file contains hidden or 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
curl -Lo minikube https://storage.googleapis.com/minikube/releases/v0.18.0/minikube-darwin-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/ |
This file contains hidden or 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
$ yarn | |
yarn install v0.23.2 | |
info No lockfile found. | |
[1/4] 🔍 Resolving packages... | |
[2/4] 🚚 Fetching packages... | |
[3/4] 🔗 Linking dependencies... | |
[4/4] 📃 Building fresh packages... | |
success Saved lockfile. | |
✨ Done in 0.44s. |
This file contains hidden or 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
-- use regacy sqlはoff | |
SELECT | |
REGEXP_EXTRACT(textPayload,r'^(?:[^\t]*\t){0}([^\t]*).*') AS field1, | |
REGEXP_EXTRACT(textPayload,r'^(?:[^\t]*\t){1}([^\t]*).*') AS field2, | |
REGEXP_EXTRACT(textPayload,r'^(?:[^\t]*\t){2}([^\t]*).*') AS field3, | |
... | |
FROM | |
`projectname.datasetname.somelogs_*` | |
; |
This file contains hidden or 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
# -*- coding: utf-8 -*- | |
import json, codecs, os | |
srcdir = 'perdate/' | |
destdir = 'perdate_tsv/' | |
if not os.path.exists(destdir): | |
os.mkdir(destdir) |
This file contains hidden or 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
502 Bad Gateway: Registered endpoint failed to handle the request. |
This file contains hidden or 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# All Vagrant configuration is done below. The "2" in Vagrant.configure | |
# configures the configuration version (we support older styles for | |
# backwards compatibility). Please don't change it unless you know what | |
# you're doing. | |
Vagrant.configure("2") do |config| | |
# The most common configuration options are documented and commented below. | |
# For a complete reference, please see the online documentation at |
This file contains hidden or 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 | |
cd /Volumes/Time\ Machine/Backups.backupdb/Ikuo’s\ Mac\ mini | |
BACKUPS=(\ | |
2015-03-23-093603 | |
2015-04-13-032009 | |
2015-05-11-005904 | |
2015-06-01-000440 | |
2015-07-06-075631 |
This file contains hidden or 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 | |
# Randomly choose pods, and kubectl exec | |
# usage ./kubeexec.sh hostname | |
pod_count=$(kubectl get pods -o name | wc -l) | |
pod_index=`echo "scale=0; $pod_count * $RANDOM / 32767 + 1" | bc` | |
pod=$(kubectl get pods -o name | awk "NR==$pod_index" | sed -e 's/pod\///g') | |
/usr/local/bin/kubectl exec $pod $@ |
This file contains hidden or 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
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: counter-logger | |
spec: | |
containers: | |
- name: date-count | |
image: ubuntu:14.04 | |
args: [bash, -c, 'for ((i = 0; ; i++)); do echo "$i: $(date)" >> /var/log/datelog.log; echo $RANDOM >> /var/log/randomlog.log; sleep 3; done'] | |
volumeMounts: |