Skip to content

Instantly share code, notes, and snippets.

View hummer2k's full-sized avatar

Cornelius Adams hummer2k

View GitHub Profile
@hummer2k
hummer2k / shelly_i3_actions.yaml
Created December 30, 2020 15:29
Home Assistant Shelly i3 Blueprint
blueprint:
name: Shelly i3 Actions
description: Bind Shelly i3 button press actions
domain: automation
input:
switch:
name: Shelly i3 Switch
selector:
entity:
integration: shelly
@hummer2k
hummer2k / ffsync.service
Created April 14, 2018 12:33
systemd firefox sync service
[Unit]
Description=A gunicorn server running Mozilla's Firefox sync server
After=syslog.target network.target remote-fs.target nss-lookup.target
[Service]
Type=simple
User=pi
Group=pi
Restart=on-abort
ExecStart=/opt/ffsyncserver/local/bin/gunicorn --paste /opt/ffsyncserver/syncserver.ini
@hummer2k
hummer2k / Image.php
Last active September 14, 2017 17:26
Magento 1.x Image Helper
<?php
/**
* Class Acme_Module_Helper_Image
* @method $this rotate($angle)
* @method $this crop($top=0, $left=0, $right=0, $bottom=0)
* @method $this resize($width, $height = null)
* @method $this keepAspectRatio($value)
* @method $this keepFrame($value)
* @method $this keepTransparency($value)
@hummer2k
hummer2k / magento2-varnish-4.0.vcl
Last active August 8, 2019 09:06
Magento 2 vcl for varnish 4
vcl 4.0;
import std;
# The minimal Varnish version is 4.0
backend default {
.host = "{{ host }}";
.port = "{{ port }}";
}