Skip to content

Instantly share code, notes, and snippets.

View jhillyerd's full-sized avatar

James Hillyerd jhillyerd

View GitHub Profile
@jhillyerd
jhillyerd / automations.yaml
Created January 14, 2024 00:31
Home Assistant Auto Color Temperature
- id: '1704839258272'
alias: Auto Office Lights
description: ''
trigger:
- platform: state
entity_id:
- sensor.auto_kelvin
- platform: state
entity_id:
- binary_sensor.office_occupancy
{
description = "Home Services";
inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-21.11"; };
outputs = { self, nixpkgs }@attrs:
let
inherit (nixpkgs.lib) attrsets nixosSystem;
# List of hosts available to build.
@jhillyerd
jhillyerd / hello.go
Created July 11, 2021 17:40
HELO error repro
package main
import (
"net"
"net/smtp"
)
func main() {
conn, err := net.Dial("tcp", "localhost:2500")
if err != nil {
@jhillyerd
jhillyerd / flake.nix
Created March 12, 2021 15:26
dev shell flake
{
description = "my nixops & ansible configruation";
inputs = {
flake-utils.url = "github:numtide/flake-utils";
hello.url = "github:ihsanturk/hello-world-nix?rev=03ec3abd2def85a97425660a96aa31565cc77821";
nixops-flake.url = "github:input-output-hk/nixops-flake";
};
outputs = { self, nixpkgs, flake-utils, hello, nixops-flake }:
@jhillyerd
jhillyerd / libvirtd-ops.md
Last active August 29, 2023 03:15
Getting started with nixops and libvirtd

Enable libvirtd

Add:

virtualisation.libvirtd.enable = true;

and

users.users.<you>.extraGroups = [ "libvirtd" ];
@jhillyerd
jhillyerd / install.sh
Last active June 3, 2020 18:48
create-elm-app + elm 0.19 on NixOS
# These instructions assume you are on https://nixos.org/channels/nixos-18.09
# You will need $HOME/bin in your $PATH to use create-elm-app
# Create a empty nix profile
nix-env -S /nix/var/nix/profiles/per-user/$USER/elm19-app
# Install elm 0.19
nix-env -iA nixos.elmPackages
# Keep global node packages in $HOME, will result in bin, lib and node_packages dirs