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
""" | |
Plugin for collectd to fetch Fail2ban statistics per jail. | |
Recreated, but based on the original source code by Antti Jaakkola | |
(https://github.com/annttu/collectd-plugins). | |
To add this plugin to collectd, create a definition as below: | |
```python | |
LoadPlugin python |
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
CREATE TABLE IF NOT EXISTS collectd_metrics ( | |
time TIMESTAMPTZ NOT NULL, | |
plugin TEXT, | |
plugin_instance TEXT, | |
type_instance TEXT, | |
type TEXT, | |
host TEXT, | |
metric TEXT, | |
value DOUBLE PRECISION | |
); |
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
""" | |
Copyright (C) 2021 Bas Stottelaar <[email protected]> | |
License: Beerware | |
Disclaimer: use at your own risk | |
Usage: | |
- Install dependencies |
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
from django.contrib.auth import SESSION_KEY | |
from django.core.cache import cache | |
from django.utils.functional import SimpleLazyObject | |
from django.contrib.auth.signals import user_logged_out | |
from django.contrib.auth import get_user_model | |
from django.db.models.signals import post_save, post_delete | |
from functools import partial | |
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 | |
# Modified from https://gist.github.com/yuanying/3aa7d59dcce65470804ab43def646ab6. | |
IMAGE="ubuntu:20.04" | |
COMMAND="/bin/bash" | |
SUFFIX=$(date +%s | shasum | base64 | fold -w 10 | head -1 | tr '[:upper:]' '[:lower:]') | |
usage_exit() { | |
echo "Usage: $0 [-n namespace] [-c command] [-i image] PVC ..." 1>&2 |
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
# syntax=docker/dockerfile:experimental | |
# Compile all dependencies in a separate build environment. Note that the | |
# cache is copied to /cache as a final step, because the actual cache folder | |
# is an external mount. | |
FROM --platform=$TARGETPLATFORM python:3.8-alpine3.13 as buildenv | |
COPY requirements_base.txt requirements.txt ./ | |
RUN --mount=type=cache,target=/root/.cache \ |
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
package observable | |
import ( | |
"sync" | |
"github.com/twinj/uuid" | |
log "github.com/sirupsen/logrus" | |
) |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>ACPI</key> | |
<dict> | |
<key>DSDT</key> | |
<dict> | |
<key>Fixes</key> | |
<dict> |
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
class Knxd < Formula | |
desc "knxd is an advanced router/gateway; it can talk to all known KNX interfaces" | |
homepage "https://github.com/knxd/knxd" | |
head "https://github.com/knxd/knxd.git" | |
url "https://github.com/knxd/knxd/archive/v0.14.17.tar.gz" | |
sha256 "f1e64fd09a0bfa789e75311d4ac11353ebe83cca49929159f02b9bc41960afdd" | |
depends_on "argp-standalone" => :build | |
depends_on "autoconf" => :build | |
depends_on "automake" => :build |
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
#ifndef CUSTOM_EVENTS_H_INCLUDED | |
#define CUSTOM_EVENTS_H_INCLUDED | |
extern void Custom_Initialize(); | |
extern void Custom_Timer100MS(); | |
extern void Custom_SetBedTemp(float temp, bool beep); | |
extern void Custom_Kill(bool only_steppers); | |
extern void Custom_JamDetected(int8_t id); | |
extern void Custom_HeaterDecoupled(int8_t id); | |
extern void Custom_HeaterDefect(int8_t id); |
NewerOlder