Skip to content

Instantly share code, notes, and snippets.

View fpletz's full-sized avatar
🦺
building

Franz Pletz fpletz

🦺
building
  • Munich, Germany
  • 10:43 (UTC +02:00)
View GitHub Profile
@fpletz
fpletz / hm-config.nix
Created July 28, 2023 19:10
NixOS home-manager wayland screensharing
{ pkgs, ... }:
{
services.pipewire = {
enable = true;
};
xdg.portal = {
enable = true;
wlr = {
enable = true;
@fpletz
fpletz / configuration.nix
Created November 18, 2022 19:59
tuigreet nixos config
{
services.greetd = {
enable = true;
settings.default_session.command = "${lib.makeBinPath [pkgs.greetd.tuigreet]}/tuigreet --time --cmd ${cfg.greetCmd}";
};
}
@fpletz
fpletz / configuration.nix
Created February 23, 2021 21:43
nixos docker zfs
{
systemd.services.docker.path = with pkgs; [ zfs ];
services = {
docker = {
enable = true;
extraOptions = "--storage-driver zfs --exec-opt native.cgroupdriver=systemd --bip=192.168.234.1/24";
autoPrune = {
enable = true;
dates = "weekly";
@fpletz
fpletz / module.nix
Created June 19, 2020 09:05
NixOS module test skeleton
{ config, lib, ... }:
with lib;
let
cfg = config.foo.bar;
in
{
@fpletz
fpletz / esphome-print-async.py
Last active February 23, 2024 00:47
aioesphomeapi minimal examples
#!/usr/bin/env python3
import aioesphomeapi
import asyncio
async def main():
loop = asyncio.get_running_loop()
cli = aioesphomeapi.APIClient(loop, "foobarhostname", 6053, "foobarpassword")
await cli.connect(login=True)
{
services.dovecot2 = {
modules = with pkgs; [ dovecot_pigeonhole ];
extraConfig = ''
protocol lmtp {
mail_plugins = $mail_plugins sieve
}
service managesieve-login {
inet_listener sieve {
### Keybase proof
I hereby claim:
* I am fpletz on github.
* I am fpletz (https://keybase.io/fpletz) on keybase.
* I have a public key whose fingerprint is 8A39 615D CE78 AF08 2E23 F303 846F DED7 7926 17B4
To claim this, I am signing this object:
@fpletz
fpletz / gist:cb1bfaf976921a28436821e6e5182fd0
Last active September 17, 2017 12:51
cache.nixos.community mirror
# Mirrors only the NixOS Binary Cache from cache.nixos.community
let
cacheHostname = "cache.nixos.ffmuc.net";
cacheFolder = "/srv/nixos-cache";
in {
systemd.services."rsync-nixos-cache" = {
boot.kernelPackages = pkgs.linuxPackages_custom rec {
version = "4.11.4";
src = pkgs.fetchurl {
url = "mirror://kernel/linux/kernel/v4.x/linux-${version}.tar.xz";
sha256 = "144a8ianp6sy057pbhnssg6xs4f3dc5cwwkz8d4q9jzpd87fdm43";
};
configfile = ./customKernel.config;
};
{
test = { pkgs, lib, ... }: with lib; {
virtualisation.memorySize = 512;
virtualisation.graphics = false;
networking.firewall.enable = false;
services.rmilter.enable = false;
};
}