Skip to content

Instantly share code, notes, and snippets.

@davidjb
davidjb / configuration.yaml
Last active October 25, 2023 15:48
MQTT-based water meter configuration for Home Assistant
# MQTT Broker - mosquitto
mqtt:
broker: localhost
port: 1883
utility_meter:
water_usage_mains_hourly:
source: sensor.water_meter
cycle: hourly
water_usage_mains_daily:
@mlapida
mlapida / EC2-Stopped-Tagged-Lambda.py
Last active May 29, 2024 06:00
Using a lambda function, stop all instances that are tagged appropriately.
import boto3
import logging
#setup simple logging for INFO
logger = logging.getLogger()
logger.setLevel(logging.INFO)
#define the connection
ec2 = boto3.resource('ec2')
@henrysher
henrysher / reinvent.md
Last active July 9, 2021 07:38
link for reinvent slides
@michaelcoyote
michaelcoyote / Avamar_NodeInfo_Commands.txt
Created August 15, 2014 18:00
Commands to get the node serials and other info from Avamar nodes. Not a script, use wisely
# This is not a script, please paste commands direclty into a ssh/putty window.
# get the DPN status
status.dpn
# set the ssh agent keys
ssh-agent bash