Skip to content

Instantly share code, notes, and snippets.

View 0xVesion's full-sized avatar

Vincent Engel 0xVesion

View GitHub Profile
async function fetchSheetValues({id, name, apiKey}) {
const url = 'https://sheets.googleapis.com/v4/spreadsheets/' + id + '/values/' + name + '?alt=json&key=' + apiKey;
const json = await new Request(url).loadJSON()
console.log(`Head to this url to see the raw data: ${url}`);
return json.values
}
function buildWidget(data) {
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
cat <<EOF | tee /etc/apt/sources.list.d/kubernetes.list
deb https://apt.kubernetes.io/ kubernetes-xenial main
EOF
apt update
apt install -y kubelet kubeadm kubectl
apt-mark hold kubelet kubeadm kubectl
@0xVesion
0xVesion / stress.sh
Last active June 3, 2020 17:08
RPI 4 Stress test for measuring temps
#!/bin/bash
clear
for i in {1..10}
do
vcgencmd measure_temp
sysbench --test=cpu --cpu-max-prime=10000 --num-threads=4 run >/dev/null 2>&1
done