package main | |
import ( | |
"fmt" | |
"math/rand" | |
"time" | |
) | |
var manos [][]int | |
var baraja []int |
package main | |
// http://blog.golang.org/go-image-package | |
// http://d.hatena.ne.jp/taknb2nch/20131231/1388500659 | |
// https://blog.golang.org/go-imagedraw-package | |
import ( | |
"flag" | |
"fmt" | |
"image" | |
"image/draw" |
#!/bin/bash | |
sudo apt-get update && sudo apt-get upgrade | |
sudo apt-get install makepasswd rcs perl-doc libio-tee-perl git libmail-imapclient-perl libdigest-md5-file-perl libterm-readkey-perl libfile-copy-recursive-perl build-essential make automake libunicode-string-perl | |
cd $HOME | |
git clone git://github.com/imapsync/imapsync.git --depth 1 | |
cd imapsync | |
sudo make install |
Build the following and make it run as fast as you possibly can using Python 3 (vanilla). The faster it runs, the more you will impress us!
Your code should:
- Download this 2.2GB file: https://s3.amazonaws.com/carto-1000x/data/yellow_tripdata_2016-01.csv
- Count the lines in the file
- Calculate the average value of the tip_amount field.
All of that in the most efficient way you can come up with.
ALERT deleted_container_rate_on_hosts | |
IF sum without(instance) (rate(engine_daemon_container_actions_seconds_count{action="delete"}[1m])) > 0.1 | |
FOR 1m | |
ANNOTATIONS { | |
summary = "DELETED CONTAINER RATE WARNING ON '{{ $labels.instance }}'", | |
description = "{{ $labels.instance }} has a HIGH rate of deleted containers. Deleted container rate is {{ humanize $value}}%.", | |
} |
There is an increasing count of applications which use Authy for two-factor authentication. However many users who aren't using Authy, have their own authenticator setup up already and do not wish to use two applications for generating passwords.
Since I use 1Password for all of my password storing/generating needs, I was looking for a solution to use Authy passwords on that. I couldn't find any completely working solutions, however I stumbled upon a gist by Brian Hartvigsen. His post had a neat code with it to generate QR codes (beware, through Google) for you to use on your favorite authenticator.
His method is to extract the secret keys using Authy's Google Chrome app via Developer Tools. If this was not possible, I guess people would be reverse engineering the Android app or something like that. But when I tried that code, nothing appeared on the screen. My gues
Following twitter thread about running kube-web-view in k8spin: https://twitter.com/AngelBarrera92/status/1162649686588690437?s=20
- Get a VM
- Install Docker
curl -sSL https://get.docker.com/ | sh
- Install gvisor (following official guide https://gvisor.dev/docs/user_guide/docker/#install-gvisor)
3.1 Run the following script
(
command: | |
# interpeted as a string | |
- helm push $${repo}:${DRONE_TAG} | |
# interpreted as string | |
- helm push foo:bar | |
# if ${DRONE_TAG} is missing or empty, | |
# it will be rendered as follows. |