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 python3 | |
# Uses the Mailgun API to save logs to JSON file | |
# Set environment variables MAILGUN_API_KEY and MAILGUN_SERVER | |
# Optionally set MAILGUN_LOG_DAYS to number of days to retrieve logs for | |
# Based on https://stackoverflow.com/a/49825979 | |
# See API guide https://documentation.mailgun.com/en/latest/api-intro.html#introduction | |
import os | |
import json | |
import requests | |
from datetime import datetime, timedelta |
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
# Recreate cowdata | |
systemctl stop docker | |
umount -f /fastdata | |
umount -f /cowdata | |
# Above umount needs to succeed | |
# verify cowdata and fastdata are unmounted | |
df -h |
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
PyYAML-3.10-11.el7.x86_64 | |
acl-2.2.51-15.el7.x86_64 | |
audit-libs-2.8.5-4.el7.x86_64 | |
audit-libs-python-2.8.5-4.el7.x86_64 | |
basesystem-10.0-7.el7.centos.noarch | |
bash-4.2.46-34.el7.x86_64 | |
bc-1.06.95-13.el7.x86_64 | |
binutils-2.27-43.base.el7_8.1.x86_64 | |
bzip2-libs-1.0.6-13.el7.x86_64 | |
ca-certificates-2019.2.32-76.el7_7.noarch |
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
%%% led_controller is a module to toggle LEDs wired to gpio pins on the raspberry pi | |
-module(led_controller). | |
-behavior(gen_server). | |
-export([start_link/1]). | |
% standard gen_server | |
-export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2, code_change/3]). | |
% Public Interface | |
-export([on/1, off/1, blink/2]). | |
% Don't call these directly | |
-export([blink_cast/2]). |