Compare commits

...

37 Commits

Author SHA1 Message Date
Tom Alexander
9bc3aed323
Add ndproxy to support neighbor discovery of VMs from the public internet. 2025-12-07 14:31:15 -05:00
Tom Alexander
613204d9fa
Enable ipv6 cluster in the firewall. 2025-12-07 14:19:24 -05:00
Tom Alexander
c23a99bd41
Add support for multiple 9p directories. 2025-12-07 10:32:56 -05:00
Tom Alexander
32d276c467
Add IP allocations for new nix-based kubernetes cluster. 2025-11-30 19:50:45 -05:00
Tom Alexander
6e14356a13
Enable type-checking by default in vscode for python. 2025-11-30 19:17:49 -05:00
Tom Alexander
c5e7b983ec
Disable 6ghz.
Currently, I get a lot of dropped packets on 6ghz. I suspect it is a bug in the drivers/firmware.
2025-09-28 20:57:32 -04:00
Tom Alexander
25957105c9
Add support for preventing OOM kill on certain VMs. 2025-09-27 19:02:06 -04:00
Tom Alexander
daaf427286
Update to the new GPG key. 2025-09-23 19:51:38 -04:00
Tom Alexander
c96c4d3ddb
Unbind shift+enter to stop unintentionally running python code. 2025-09-19 10:04:09 -04:00
Tom Alexander
b72fa0edff
Disable AI firefox stuff. 2025-09-19 10:03:24 -04:00
Tom Alexander
052c051c75
Switch to abm level 2.
Recent kernels have made the screen dimmer. Switching to ABM level 2 has compensated for that.
2025-09-16 17:57:53 -04:00
Tom Alexander
79a2ec6f53
Add rg jail. 2025-09-07 15:37:29 -04:00
Tom Alexander
7c506f9e7f
Add d2. 2025-09-07 15:11:11 -04:00
Tom Alexander
40dc19eaea
Disable nfsd. 2025-08-31 19:58:39 -04:00
Tom Alexander
2aec6d2411
Add support for mounting a host directory into the VM via virtio-9p. 2025-08-30 16:53:03 -04:00
Tom Alexander
97149b9196
Fix firewall blocking to host machine.
The firewall was not working so all traffic was making it through to the host system.
2025-08-30 15:07:57 -04:00
Tom Alexander
4633a97262
Wire memory in router VMs. 2025-08-27 20:16:06 -04:00
Tom Alexander
9ff8835e0a
Scope back navigation to the editor. 2025-08-27 16:51:51 -04:00
Tom Alexander
2f07067bda
Merge branch 'bhyve_rc' 2025-08-26 22:30:21 -04:00
Tom Alexander
2d94825d17
Add timeouts. 2025-08-26 22:29:59 -04:00
Tom Alexander
d1c6e358d4
Update vscode config. 2025-08-26 22:29:58 -04:00
Tom Alexander
54060aada6
Add delay between starts. 2025-08-26 22:29:58 -04:00
Tom Alexander
313c159a3e
Integrate code to launch the VMs. 2025-08-26 22:29:58 -04:00
Tom Alexander
187a7aebe9
Add a bhyverc script using pidfiles. 2025-08-26 22:29:58 -04:00
Tom Alexander
ab246f61dd
Add speech-dispatcher for text to speech in firefox. 2025-08-23 16:23:22 -04:00
Tom Alexander
04c991e775
Enable hardware accelerated encoding in chromium. 2025-08-09 13:30:31 -04:00
Tom Alexander
ca1a569013
Static ip address for certificate renewals on home server. 2025-05-24 18:28:12 -04:00
Tom Alexander
6578d64b50
Format typescript on save in vscode. 2025-05-19 16:27:00 -04:00
Tom Alexander
22cf52d490
Fix screen scaling during screen sharing. 2025-04-01 13:41:07 -04:00
Tom Alexander
5b276081d1
Forward port to hydra ssh. 2025-03-23 20:41:52 -04:00
Tom Alexander
ff1217c65d
Add hydra IP address binding. 2025-03-23 16:54:56 -04:00
Tom Alexander
9319fc4bc5
Add DMARC record to domain. 2025-03-08 13:34:27 -05:00
Tom Alexander
b1bea7224f
Integrate some git config suggestions from https://blog.gitbutler.com/how-git-core-devs-configure-git/ . 2025-02-26 13:29:44 -05:00
Tom Alexander
28b61ff95a
Show the project on the mode line in emacs. 2025-02-24 14:04:41 -05:00
Tom Alexander
abf5f81d21
Do not show window borders when it is the only window on the workspace. 2025-02-24 12:19:22 -05:00
Tom Alexander
d9150880d3
Fix org-mode shift-arrow keys and add cmake support. 2025-02-24 12:17:32 -05:00
Tom Alexander
515e910487
Switch back to LTS kernel. 2025-02-24 12:15:37 -05:00
63 changed files with 1111 additions and 205 deletions

View File

@ -14,6 +14,8 @@ pf_config: "mrmanager_pf.conf"
pflog_conf:
- name: 0
dev: pflog0
- name: 1
dev: pflog1
cputype: "amd"
hwpstate: true
etc_hosts: {}
@ -36,6 +38,10 @@ jail_list:
enabled: true
conf:
src: public_dns
- name: rg
enabled: true
conf:
src: rg
bhyve_dataset: zdata/vm
bhyve_canmount: "on"
# efi_dev: /dev/gpt/EFI

View File

@ -53,7 +53,7 @@
- javascript
- launch_keyboard
- lvfs
- restaurant_health_rating
# - restaurant_health_rating
- wasm
- noise_suppression
@ -104,6 +104,7 @@
- wireguard
- emacs
- mrmanager
- ndproxy
- hosts: admin_git:public_dns
vars:

View File

@ -1,35 +1,54 @@
[user]
email = tom@fizz.buzz
name = Tom Alexander
signingkey = D3A179C9A53C0EDE
signingkey = 36C99E8B3C39D85F
[push]
default = simple
default = simple # (default since 2.0)
[alias]
lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
bh = log --oneline --branches=* --remotes=* --graph --decorate
amend = commit --amend --no-edit
authorcount = shortlog --summary --numbered --all --no-merges
[core]
excludesfile = ~/.gitignore_global
[commit]
gpgsign = true
verbose = true
[pull]
rebase = true
[log]
date = local
[init]
defaultBranch = main
# Use meld for `git difftool` and `git mergetool`
[diff]
tool = meld
tool = meld # Use meld for `git difftool` and `git mergetool`
algorithm = histogram
colorMoved = plain
mnemonicPrefix = true
renames = true
[difftool]
prompt = false
[difftool "meld"]
cmd = meld "$LOCAL" "$REMOTE"
[merge]
tool = meld
conflictStyle = zdiff3
[mergetool "meld"]
# Make the middle pane start with partially-merged contents:
cmd = meld "$LOCAL" "$MERGED" "$REMOTE" --output "$MERGED"
# Make the middle pane start without any merge progress:
# cmd = meld "$LOCAL" "$BASE" "$REMOTE" --output "$MERGED"
[column]
ui = auto
[branch]
sort = -committerdate
[tag]
sort = version:refname
[fetch]
prune = true
pruneTags = true
all = true
[rebase]
autoSquash = true
autoStash = true
updateRefs = false

View File

@ -1,33 +1,38 @@
[user]
email = ThomasA.Alexander@hmhn.org
name = Tom Alexander
signingkey = D3A179C9A53C0EDE
signingkey = 36C99E8B3C39D85F
[push]
default = simple
default = simple # (default since 2.0)
[alias]
lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
bh = log --oneline --branches=* --remotes=* --graph --decorate
amend = commit --amend --no-edit
authorcount = shortlog --summary --numbered --all --no-merges
[core]
excludesfile = ~/.gitignore_global
[commit]
gpgsign = true
verbose = true
[pull]
rebase = true
[log]
date = local
[init]
defaultBranch = main
# Use meld for `git difftool` and `git mergetool`
[diff]
tool = meld
tool = meld # Use meld for `git difftool` and `git mergetool`
algorithm = histogram
colorMoved = plain
mnemonicPrefix = true
renames = true
[difftool]
prompt = false
[difftool "meld"]
cmd = meld "$LOCAL" "$REMOTE"
[merge]
tool = meld
conflictStyle = zdiff3
[mergetool "meld"]
# Make the middle pane start with partially-merged contents:
cmd = meld "$LOCAL" "$MERGED" "$REMOTE" --output "$MERGED"
@ -35,3 +40,19 @@
# cmd = meld "$LOCAL" "$BASE" "$REMOTE" --output "$MERGED"
[includeIf "gitdir:/bridge/"]
path = /bridge/git/machine_setup/ansible/roles/base/files/gitconfig_home
[includeIf "gitdir:/persist/"]
path = /bridge/git/machine_setup/ansible/roles/base/files/gitconfig_home
[column]
ui = auto
[branch]
sort = -committerdate
[tag]
sort = version:refname
[fetch]
prune = true
pruneTags = true
all = true
[rebase]
autoSquash = true
autoStash = true
updateRefs = false

View File

@ -153,6 +153,7 @@ function start_vm {
-D \
-c $CPU_CORES \
-m $MEMORY \
-S \
-H \
-P \
-o 'rtc.use_localtime=false' \
@ -216,7 +217,7 @@ EOF
mkpeer ${host_interface_name}: bridge ether link0
name ${host_interface_name}:ether $bridge_name
EOF
ifconfig $(ngctl msg "${host_interface_name}:" getifname | grep Args | cut -d '"' -f 2) name "${host_interface_name}" "$ip_range" up
ifconfig "$(ngctl msg "${host_interface_name}:" getifname | grep Args | cut -d '"' -f 2)" name "${host_interface_name}" "$ip_range" up
fi
}

View File

@ -0,0 +1,478 @@
#!/usr/bin/env bash
#
set -euo pipefail
IFS=$'\n\t'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# Share a host directory to the guest via 9pfs.
#
# Inside the VM run:
# mount -t virtfs -o trans=virtio sharename /some/vm/path
# mount -t 9p -o cache=mmap -o msize=512000 sharename /mnt/9p
# mount -t 9p -o trans=virtio,cache=mmap,msize=512000 bind9p /path/to/mountpoint
# bhyve_options="-s 28,virtio-9p,sharename=/"
# Enable Sound
# bhyve_options="-s 16,hda,play=/dev/dsp,rec=/dev/dsp"
# Example usage:
#
# doas bhyverc create-disk zdata/vm/poudriere /vm/poudriere 10
# doas bhyverc start poudriere zdata/vm/poudriere /vm/poudriere /vm/iso/FreeBSD-13.2-RELEASE-amd64-bootonly.iso
# doas bhyverc start poudriere zdata/vm/poudriere /vm/poudriere
: ${VERBOSE:="NO"} # or YES
if [ "$VERBOSE" = "YES" ]; then
set -x
fi
: ${CPU_CORES:="1"}
: ${MEMORY:="1G"}
: ${NETWORK:="NAT"} # or RAW or BOTH
: ${IP_RANGE:="10.215.1.1/24"} # Ignored for RAW networks
: ${INTERFACE_NAME:="jail_nat"} # or the external interface like lagg0 for RAW networks
: ${BRIDGE_NAME:="bridge_$INTERFACE_NAME"} # or bridge_raw for RAW networks
: ${VNC_ENABLE:="NO"}
: ${VNC_LISTEN:="127.0.0.1:5900"}
: ${VNC_WIDTH:="1920"}
: ${VNC_HEIGHT:="1080"}
: ${BIND9P:=""}
: ${PREVENT_OOM:="NO"}
: "${CD:=}"
: ${SHUTDOWN_TIMEOUT:="600"} # 10 minutes
############## Setup #########################
function die {
local status_code="$1"
shift
(>&2 echo "${@}")
exit "$status_code"
}
function log {
(>&2 echo "${@}")
}
############## Program #########################
function main {
local cmd
cmd=$1
shift
if [ "$cmd" = "start" ]; then
init
start "${@}"
elif [ "$cmd" = "stop" ]; then
init
stop "${@}"
elif [ "$cmd" = "status" ]; then
init
status "${@}"
elif [ "$cmd" = "console" ]; then
init
console "${@}"
elif [ "$cmd" = "_start_body" ]; then
init
start_body "${@}"
elif [ "$cmd" = "create-disk" ]; then
create_disk "${@}"
else
(>&2 echo "Unknown command: $cmd")
exit 1
fi
}
function start {
local num_vms="$#"
if [ "$num_vms" -eq 0 ]; then
log "No VMs specified."
return 0
fi
while [ "$#" -gt 0 ]; do
local name="$1"
shift 1
log "Starting VM $name."
start_one "$name"
[ "$#" -eq 0 ] || sleep 5
done
}
function start_one {
local name="$1"
local tmux_name="$name"
/usr/local/bin/tmux new-session -d -s "$tmux_name" "$0" "_start_body" "$name"
# /usr/local/bin/tmux new-session -d -s "$tmux_name" "/usr/bin/env VNC_ENABLE=NO VNC_LISTEN=0.0.0.0:5900 /usr/local/bin/bash /home/talexander/launch_opnsense.bash"
}
function launch_pidfile {
local pidfile="$1"
shift 1
mkdir -p "$(dirname "$pidfile")"
cat > "${pidfile}" <<< "$$"
set -x
exec "${@}"
}
export -f launch_pidfile
function stop {
local num_vms="$#"
if [ "$num_vms" -eq 0 ]; then
log "No VMs specified."
return 0
fi
while [ "$#" -gt 0 ]; do
local name="$1"
shift 1
log "Stopping VM $name."
stop_one "$name"
[ "$#" -eq 0 ] || sleep 5
done
}
function stop_one {
local name="$1"
local pidfile="/run/bhyverc/${name}/pid"
if [ ! -e "$pidfile" ]; then
log "Pid file $pidfile does not exist."
return 0
fi
local bhyve_pid
bhyve_pid=$(cat "$pidfile")
if ps -p "$bhyve_pid" >/dev/null; then
# Send ACPI shutdown command
log "Sending ACPI shutdown to ${name}:${bhyve_pid}."
kill -SIGTERM "$bhyve_pid"
fi
local timeout_start timeout_end
timeout_start=$(date +%s)
while ps -p "$bhyve_pid" >/dev/null; do
timeout_end=$(date +%s)
if [ $((timeout_end-timeout_start)) -ge "$SHUTDOWN_TIMEOUT" ]; then
log "${name}:${bhyve_pid} took more than $SHUTDOWN_TIMEOUT seconds to shut down. Hard powering down."
break
fi
log "Waiting for ${name}:${bhyve_pid} to exit."
sleep 2
done
bhyvectl "--vm=$name" --destroy || true
local timeout_start timeout_end
timeout_start=$(date +%s)
while ps -p "$bhyve_pid" >/dev/null; do
timeout_end=$(date +%s)
if [ $((timeout_end-timeout_start)) -ge "$SHUTDOWN_TIMEOUT" ]; then
log "${name}:${bhyve_pid} took more than $SHUTDOWN_TIMEOUT seconds to hard power down. Giving up."
break
fi
log "Waiting for ${name}:${bhyve_pid} to hard power down."
sleep 2
done
rm -f "$pidfile"
log "Finished stopping $name."
}
function status {
local num_vms="$#"
if [ "$num_vms" -gt 0 ]; then
for name in "$@"; do
status_one "$name"
done
else
log "No VMs specified."
fi
}
function status_one {
local name="$1"
local pidfile="/run/bhyverc/${name}/pid"
if [ ! -e "$pidfile" ]; then
log "$name is not running."
return 0
fi
local bhyve_pid
bhyve_pid=$(cat "$pidfile")
if ! ps -p "$bhyve_pid" >/dev/null; then
log "$name is not running."
return 0
fi
log "$name is running as pid $bhyve_pid."
}
function console {
local num_vms="$#"
if [ "$num_vms" -gt 0 ]; then
for name in "$@"; do
log "Attaching to console of VM $name."
console_one "$name"
done
else
log "No VMs specified."
fi
}
function console_one {
local name="$1"
local tmux_name="$name"
exec tmux a -t "$tmux_name"
}
function init {
mkdir -p /run/bhyverc
}
############## Bhyve ###########################
function create_disk {
local zfs_path="$1"
local mount_path="$2"
local gigabytes="$3"
zfs create -o "mountpoint=$mount_path" "$zfs_path"
cp /usr/local/share/edk2-bhyve/BHYVE_UEFI_VARS.fd "${mount_path}/"
tee "${mount_path}/settings" <<EOF
CPU_CORES="$CPU_CORES"
MEMORY="$MEMORY"
NETWORK="$NETWORK"
IP_RANGE="$IP_RANGE"
BRIDGE_NAME="$BRIDGE_NAME"
INTERFACE_NAME="$INTERFACE_NAME"
EOF
zfs create -s "-V${gigabytes}G" -o volmode=dev -o primarycache=metadata -o secondarycache=none "$zfs_path/disk0"
}
function start_body {
local name="$1"
local zfs_path="zdata/vm/$name"
local mount_path="/vm/$name"
if [ -e "${mount_path}/settings" ]; then
source "${mount_path}/settings"
fi
local mount_cd="$CD"
local host_interface_name="$INTERFACE_NAME" # for raw, external interface
local bridge_name="$BRIDGE_NAME"
local ip_range="$IP_RANGE" # for raw this value does not matter
local mac_address
mac_address=$(calculate_mac_address "$name")
if [ "$PREVENT_OOM" = "YES" ]; then
protect -d -i -p "$$"
fi
local entry parsed_item
local additional_args=()
local next_pcie_slot=10
if [ "$NETWORK" = "NAT" ]; then
assert_bridge "$host_interface_name" "$bridge_name" "$ip_range"
local bridge_link_name=$(detect_available_link "${bridge_name}")
additional_args+=("-s" "2:0,virtio-net,netgraph,path=${bridge_name}:,peerhook=${bridge_link_name},mac=${mac_address}")
elif [ "$NETWORK" = "RAW" ]; then
assert_raw "$host_interface_name" "$bridge_name"
local bridge_link_name=$(detect_available_link "${bridge_name}")
additional_args+=("-s" "2:0,virtio-net,netgraph,path=${bridge_name}:,peerhook=${bridge_link_name},mac=${mac_address}")
elif [ "$NETWORK" = "BOTH" ]; then
assert_bridge "jail_nat" "$bridge_name" "$ip_range"
assert_raw "$host_interface_name" "bridge_raw"
local bridge_link_name=$(detect_available_link "${bridge_name}")
local raw_bridge_link_name=$(detect_available_link "bridge_raw")
local raw_mac_address=$(calculate_mac_address "${name}_raw")
additional_args+=("-s" "2:0,virtio-net,netgraph,path=${bridge_name}:,peerhook=${bridge_link_name},mac=${mac_address}")
additional_args+=("-s" "3:0,virtio-net,netgraph,path=bridge_raw:,peerhook=${raw_bridge_link_name},mac=${raw_mac_address}")
else
die 1 "Unrecognized NETWORK type $NETWORK"
fi
if [ -n "$BIND9P" ]; then
if [[ "$BIND9P" = *":"* ]]; then
IFS=':' read -ra entry <<<"$BIND9P"
for item in "${entry[@]}"; do
IFS='=' read -ra parsed_item <<<"$item"
additional_args+=("-s" "${next_pcie_slot},virtio-9p,${parsed_item[0]}=${parsed_item[1]}")
next_pcie_slot=$((next_pcie_slot+1))
done
else
additional_args+=("-s" "${next_pcie_slot},virtio-9p,bind9p=${BIND9P}")
next_pcie_slot=$((next_pcie_slot+1))
fi
fi
# -H release the CPU when guest issues HLT instruction. Otherwise 100% of core will be consumed.
# -s 3,ahci-cd,/vm/.iso/archlinux-2023.04.01-x86_64.iso \
# -s 29,fbuf,tcp=0.0.0.0:5900,w=1920,h=1080,wait \
# -s 29,fbuf,tcp=0.0.0.0:5900,w=1920,h=1080 \
# TODO: Look into using nmdm instead of stdio for serial console
if [ -n "$mount_cd" ]; then
additional_args+=("-s" "5,ahci-cd,$mount_cd")
fi
if [ "$VNC_ENABLE" = "YES" ]; then
additional_args+=("-s" "${next_pcie_slot},fbuf,tcp=$VNC_LISTEN,w=$VNC_WIDTH,h=$VNC_HEIGHT")
next_pcie_slot=$((next_pcie_slot+1))
fi
vms+=("$name")
while true; do
local pidfile="/run/bhyverc/${name}/pid"
trap "set +e; stop_one '${name}'" EXIT
local launch_cmd=()
launch_cmd+=(
launch_pidfile "$pidfile"
bhyve
-D
-c "$CPU_CORES"
-m "$MEMORY"
-S
-H
-o 'rtc.use_localtime=false'
-s "0,hostbridge"
-s "4,nvme,/dev/zvol/${zfs_path}/disk0"
-s "${next_pcie_slot},xhci,tablet"
-s "$((next_pcie_slot+1)),lpc" -l "com1,stdio"
-l "bootrom,/usr/local/share/uefi-firmware/BHYVE_UEFI.fd,${mount_path}/BHYVE_UEFI_VARS.fd"
"${additional_args[@]}"
"$name"
)
set +e
rm -f "$pidfile"
(
IFS=$' \n\t'
set -ex
bash -c "${launch_cmd[*]}"
)
local exit_code=$?
log "Exit code ${exit_code}"
set -e
if [ $exit_code -eq 0 ]; then
echo "Rebooting."
sleep 5
elif [ $exit_code -eq 1 ]; then
echo "Powered off."
break
elif [ $exit_code -eq 2 ]; then
echo "Halted."
break
elif [ $exit_code -eq 3 ]; then
echo "Triple fault."
break
elif [ $exit_code -eq 4 ]; then
echo "Exited due to an error."
break
fi
done
}
function detect_available_link {
local bridge_name="$1"
local linknum=1
while true; do
local link_name="link${linknum}"
if ! ng_exists "${bridge_name}:${link_name}"; then
echo "$link_name"
return
fi
linknum=$((linknum + 1))
if [ "$linknum" -gt 90 ]; then
(>&2 echo "No available links on bridge $bridge_name")
exit 1
fi
done
}
function assert_bridge {
local host_interface_name="$1"
local bridge_name="$2"
local ip_range="$3"
if ! ng_exists "${bridge_name}:"; then
ngctl -d -f - <<EOF
mkpeer . eiface hook ether
name .:hook $host_interface_name
EOF
ngctl -d -f - <<EOF
mkpeer ${host_interface_name}: bridge ether link0
name ${host_interface_name}:ether $bridge_name
EOF
ifconfig "$(ngctl msg "${host_interface_name}:" getifname | grep Args | cut -d '"' -f 2)" name "${host_interface_name}" "$ip_range" up
fi
}
function assert_raw {
local extif="$1"
local bridge_name="$2"
kldload -n ng_bridge ng_eiface ng_ether
if ! ng_exists "${bridge_name}:"; then
ngctlcat <<EOF
# Create a bridge.
mkpeer $extif: bridge lower link0
# Assign a name to the bridge.
name $extif:lower ${bridge_name}
# Since the host is also using $extif, we need to connect the upper hook also. Otherwise we will lose connectivity.
connect $extif: ${bridge_name}: upper link1
# Enable promiscuous mode so the host ethernet adapter accepts packets for all addresses
msg $extif: setpromisc 1
# Do not overwrite source address on packets
msg $extif: setautosrc 0
EOF
fi
}
function ng_exists {
ngctl status "${1}" >/dev/null 2>&1
}
function calculate_mac_address {
local name="$1"
local source
source=$(md5 -r -s "$name" | awk '{print $1}')
echo "06:${source:0:2}:${source:2:2}:${source:4:2}:${source:6:2}:${source:8:2}"
}
function find_available_port {
local start_port="$1"
local port="$start_port"
while true; do
sockstat -P tcp -p 443
port=$((port + 1))
done
}
function ngctlcat {
if [ "$VERBOSE" = "YES" ]; then
tee /dev/tty | ngctl -d -f -
else
ngctl -d -f -
fi
}
main "${@}"

View File

@ -0,0 +1,37 @@
#!/bin/sh
#
# REQUIRE: LOGIN FILESYSTEMS
# PROVIDE: bhyverc
# KEYWORD: shutdown
. /etc/rc.subr
name=bhyverc
rcvar=${name}_enable
start_cmd="${name}_start"
stop_cmd="${name}_stop"
status_cmd="${name}_status"
console_cmd="${name}_console"
extra_commands="console"
load_rc_config $name
bhyverc_start() {
export PATH="$PATH:/usr/local/bin"
exec /usr/local/bin/bhyverc start "${@}"
}
bhyverc_status() {
export PATH="$PATH:/usr/local/bin"
exec /usr/local/bin/bhyverc status "${@}"
}
bhyverc_stop() {
export PATH="$PATH:/usr/local/bin"
exec /usr/local/bin/bhyverc stop "${@}"
}
bhyverc_console() {
export PATH="$PATH:/usr/local/bin"
exec /usr/local/bin/bhyverc console "${@}"
}
run_rc_command "$@"

View File

@ -22,6 +22,25 @@
loop:
- src: bhyve_netgraph_bridge.bash
dest: /usr/local/bin/bhyve_netgraph_bridge
- src: bhyverc.bash
dest: /usr/local/bin/bhyverc
- name: Install rc script
copy:
src: "files/{{ item.src }}"
dest: "/usr/local/etc/rc.d/{{ item.dest|default(item.src) }}"
owner: root
group: wheel
mode: 0755
loop:
- src: bhyverc.sh
dest: bhyverc
- name: Enable bhyverc
community.general.sysrc:
name: bhyverc_enable
value: "YES"
path: /etc/rc.conf.d/bhyverc
- name: Create zfs dataset
zfs:

View File

@ -5,4 +5,4 @@ set -euo pipefail
IFS=$'\n\t'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
GPGKEY=27DE40D9B8455C1B exec aur sync --makepkg-conf /etc/aurutils/makepkg.conf -c --sign "$@"
GPGKEY=4278299FB84F6875 exec aur sync --makepkg-conf /etc/aurutils/makepkg.conf -c --sign "$@"

View File

@ -1,27 +1,27 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
mDMEXZwWGhYJKwYBBAHaRw8BAQdAfv7qozKkmf4D+5PDzADsMm4aAKDGLha7+Cu0
0H+RsWG0HlRvbSBBbGV4YW5kZXIgPHdvcmtAZml6ei5idXp6PoiQBBMWCAA4FiEE
uEgVk2PCh3kXlUvhJ95A2bhFXBsFAl+w+R0CGwMFCwkIBwIGFQoJCAsCBBYCAwEC
HgECF4AACgkQJ95A2bhFXBt6fgD+NOYnw9gz5K/q3H5LE/Jv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RWhmAwEI
B4h+BBgWCAAmFiEE0nLI1hZ/JoWUZ2ZvQngpn7hPaHUFAmjS5wwCGwwFCQPCZwAA
CgkQQngpn7hPaHUZIAD/ZwQ9sLIwuO5qPFAAkqcaNyt68O6WkD8sKaq1r/TPviAA
/j92d7cRUIkJtS8odRYlK51r9eMeTGh2npaO+j3VKCgBuDMEaNLnJRYJKwYBBAHa
Rw8BAQdAPT7jOLbozd5hacityJHniQ6UbHN+AJcb6jh5rXOnOuSIfgQYFggAJhYh
BNJyyNYWfyaFlGdmb0J4KZ+4T2h1BQJo0uclAhsgBQkDwmcAAAoJEEJ4KZ+4T2h1
rREA/3QE6suVUDl4OS2tCi4z2fh/7kjt29I3IFo+/B0AOumgAP0ao8FGqJyFC8YA
7V6T4qrXHbhlqTeofGhQ+iu7HqZVCw==
=OfDR
-----END PGP PUBLIC KEY BLOCK-----

View File

@ -40,11 +40,11 @@
command: pacman-key -a -
args:
stdin: "{{ lookup('file', pgp_key|default('gpg.asc')) }}"
when: '"B848159363C2877917954BE127DE40D9B8455C1B" not in pacmankeys.stdout'
when: '"D272C8D6167F26859467666F4278299FB84F6875" not in pacmankeys.stdout'
register: my_key_imported
- name: Sign my signing key
command: pacman-key --lsign-key "B848159363C2877917954BE127DE40D9B8455C1B"
command: pacman-key --lsign-key "D272C8D6167F26859467666F4278299FB84F6875"
when: my_key_imported.changed
- name: Build the aurutils package
@ -103,7 +103,8 @@
- /var/cache/pacman/custom/
- name: Create custom repo db
command: repo-add --new --sign /var/cache/pacman/custom/custom.db.tar "/home/{{ build_user.name }}/.config/ansible_deploy/aurutils/aurutils-*-any.pkg.tar.*"
# shell: repo-add --new --sign /var/cache/pacman/custom/custom.db.tar "/home/{{ build_user.name }}/.config/ansible_deploy/aurutils/aurutils-*-any.pkg.tar.*"
command: repo-add --new --sign /var/cache/pacman/custom/custom.db.tar
become: true
become_user: "{{ build_user.name }}"
args:

View File

@ -1,2 +1,2 @@
--ozone-platform-hint=auto
--enable-features=VaapiVideoDecoder,VaapiIgnoreDriverChecks,Vulkan,DefaultANGLEVulkan,VulkanFromANGLE
--enable-features=VaapiVideoDecoder,VaapiIgnoreDriverChecks,Vulkan,DefaultANGLEVulkan,VulkanFromANGLE,AcceleratedVideoEncoder

View File

@ -51,17 +51,27 @@
;; Persist history over Emacs restarts. Vertico sorts by history position.
(use-package savehist
;; This is an emacs built-in but we're pulling the latest version
:pin gnu
:config
(savehist-mode))
(use-package which-key
:pin gnu
:diminish
:config
(which-key-mode))
(use-package windmove
:config
(windmove-default-keybindings))
;; This is an emacs built-in but we're pulling the latest version
:pin gnu
:bind
(
("S-<up>" . windmove-up)
("S-<right>" . windmove-right)
("S-<down>" . windmove-down)
("S-<left>" . windmove-left)
)
)
(setq tramp-default-method "ssh")

View File

@ -63,6 +63,9 @@
show-trailing-whitespace t
;; Remove the line when killing it with ctrl-k
kill-whole-line t
;; Show the current project in the mode line
project-mode-line t
)
;; (setq-default fringes-outside-margins t)

View File

@ -0,0 +1,18 @@
(require 'common-lsp)
(use-package cmake-mode
:commands cmake-mode
:hook (
(cmake-mode . (lambda ()
(eglot-ensure)
(defclass my/eglot-cmake (eglot-lsp-server) ()
:documentation
"Own eglot server class.")
(add-to-list 'eglot-server-programs
'(cmake-mode . (my/eglot-cmake "cmake-language-server")))
))
)
)
(provide 'lang-cmake)

View File

@ -0,0 +1,16 @@
(defun d2-format-buffer ()
"Run prettier."
(interactive)
(run-command-on-buffer "d2" "fmt" "-")
)
(use-package d2-mode
:commands (d2-mode)
:hook (
(d2-mode . (lambda ()
;; (add-hook 'before-save-hook 'd2-format-buffer nil 'local)
))
)
)
(provide 'lang-d2)

View File

@ -7,15 +7,15 @@
:commands nix-mode
:hook (
(nix-mode . (lambda ()
;; (eglot-ensure)
;; (defclass my/eglot-nix (eglot-lsp-server) ()
;; :documentation
;; "Own eglot server class.")
(eglot-ensure)
(defclass my/eglot-nix (eglot-lsp-server) ()
:documentation
"Own eglot server class.")
;; (add-to-list 'eglot-server-programs
;; '(nix-mode . (my/eglot-nix "nixd")))
;; (add-hook 'before-save-hook 'eglot-format-buffer nil 'local)
))
(add-to-list 'eglot-server-programs
'(nix-mode . (my/eglot-nix "nixd")))
(add-hook 'before-save-hook 'eglot-format-buffer nil 'local)
))
)
)

View File

@ -1,16 +1,23 @@
(use-package org
:ensure nil
:commands org-mode
:bind (
:bind (:map org-mode-map
("C-c l" . org-store-link)
("C-c a" . org-agenda)
("C--" . org-timestamp-down)
("C-=" . org-timestamp-up)
("S-<up>" . org-shiftup)
("S-<right>" . org-shiftright)
("S-<down>" . org-shiftdown)
("S-<left>" . org-shiftleft)
)
:hook (
(org-mode . (lambda ()
(org-indent-mode +1)
))
))
;; Make windmove work in Org mode:
(org-shiftup-final . windmove-up)
(org-shiftleft-final . windmove-left)
(org-shiftdown-final . windmove-down)
(org-shiftright-final . windmove-right)
)
:config
(require 'org-tempo)
@ -38,6 +45,8 @@
;; TODO: There is an option to set the compiler, could be better than manually doing this here https://orgmode.org/manual/LaTeX_002fPDF-export-commands.html
;; (setq org-latex-compiler "lualatex")
;; TODO: nixos latex page recommends this line, figure out what it does / why its needed:
;; (setq org-preview-latex-default-process 'dvisvgm)
(setq org-latex-pdf-process
'("lualatex -shell-escape -interaction nonstopmode -output-directory %o %f"
"lualatex -shell-escape -interaction nonstopmode -output-directory %o %f"
@ -78,4 +87,8 @@
(use-package gnuplot)
(use-package graphviz-dot-mode)
(use-package htmlize
;; For syntax highlighting when exporting to HTML.
)
(provide 'lang-org)

View File

@ -4,6 +4,8 @@
:commands (treesit-install-language-grammar treesit-ready-p)
:init
(setq treesit-language-source-alist '())
:custom
(treesit-max-buffer-size 209715200) ;; 200MiB
:config
;; Default to the max level of detail in treesitter highlighting. This
;; can be overridden in each language's use-package call with:

View File

@ -38,4 +38,8 @@
(require 'lang-nix)
(require 'lang-cmake)
(require 'lang-d2)
(load-directory autoload-directory)

View File

@ -15,6 +15,7 @@
- typescript-language-server
- shellcheck
- vscode-css-languageserver
- d2 # Generating diagrams
state: present
- name: Create directories

View File

@ -7,7 +7,6 @@ firefox_config:
dom.security.https_only_mode_ever_enabled: true
extensions.activeThemeID: "firefox-compact-dark@mozilla.org"
# Disable ads
extensions.pocket.enabled: false
browser.newtabpage.activity-stream.showSponsored: false
browser.newtabpage.activity-stream.showSponsoredTopSites: false
browser.newtabpage.activity-stream.feeds.section.topstories: false
@ -21,8 +20,6 @@ firefox_config:
privacy.globalprivacycontrol.enabled: true
# Disable "studies" (slice testing)
app.shield.optoutstudies.enabled: false
# Disable attribution which is used by advertisers to track you.
dom.private-attribution.submission.enabled: false
# Disable battery status, used to track users.
dom.battery.enabled: false
# Disable that websites can get notifications if you copy, paste, or cut something from a web page, and it lets them know which part of the page had been selected.
@ -40,6 +37,8 @@ firefox_config:
privacy.fingerprintingProtection: true
# Allow sending dark mode preference to websites.
# Allow sending timezone to websites.
privacy.fingerprintingProtection.overrides: "+AllTargets,-CSSPrefersColorScheme,-JSDateTimeUTC,-CanvasExtractionBeforeUserInputIsBlocked"
privacy.fingerprintingProtection.overrides: "+AllTargets,-CSSPrefersColorScheme,-JSDateTimeUTC,-CanvasExtractionBeforeUserInputIsBlocked,-CanvasImageExtractionPrompt,-CanvasExtractionFromThirdPartiesIsBlocked"
# Disable weather on new tab page
browser.newtabpage.activity-stream.showWeather: false
browser.ml.chat.enabled: false
browser.ml.enabled: false

View File

@ -3,4 +3,5 @@
name:
- libfido2
- firefox-developer-edition
- speech-dispatcher # For TTS
state: present

View File

@ -2,7 +2,8 @@ ext_if = "lagg0"
not_ext_if = "{ !lagg0 }"
jail_nat_v4 = "{ 10.215.1.0/24 }"
not_jail_nat_v4 = "{ any, !10.215.1.0/24 }"
pub_k8s = "{ 74.80.180.136/29, !74.80.180.138 }"
# pub_k8s = "{ 74.80.180.136/29, !74.80.180.138 }"
pub_k8s = "{ 74.80.180.137, 74.80.180.139, 74.80.180.140, 74.80.180.141, 74.80.180.142 }"
dhcp = "{ bootpc, bootps }"
allow = "{ colo }"
@ -35,18 +36,22 @@ scrub in on $ext_if all fragment reassemble
nat on $ext_if inet from ! ($ext_if) to ! ($ext_if) -> ($ext_if)
rdr pass on jail_nat proto {tcp, udp} from any to 10.215.1.1 port 53 tag REDIREXTERNAL -> 1.1.1.1 port 53
rdr pass on $ext_if proto {tcp, udp} to ($ext_if) port 6443 -> 10.215.1.204 port 6443
rdr pass on $ext_if proto {tcp, udp} to ($ext_if) port 6443 tag REDIRINTERNAL -> 10.215.1.204 port 6443
rdr pass on jail_nat proto {tcp, udp} to ($ext_if) port 6443 tag REDIRINTERNAL -> 10.215.1.204 port 6443
rdr pass on $ext_if proto {tcp, udp} to ($ext_if) port 19993 -> 10.215.1.204 port 19993
rdr pass on $ext_if proto {tcp, udp} to ($ext_if) port 19993 tag REDIRINTERNAL -> 10.215.1.204 port 19993
rdr pass on jail_nat proto {tcp, udp} to ($ext_if) port 19993 tag REDIRINTERNAL -> 10.215.1.204 port 19993
rdr pass proto {tcp, udp} from $not_jail_nat_v4 to ($ext_if) port 65099 -> 10.215.1.210 port 22
rdr pass proto {tcp, udp} from $not_jail_nat_v4 to ($ext_if) port 65099 tag REDIRINTERNAL -> 10.215.1.210 port 22
rdr pass proto {tcp, udp} from $jail_nat_v4 to ($ext_if) port 65099 tag REDIRINTERNAL -> 10.215.1.210 port 22
rdr pass proto {tcp, udp} from $not_jail_nat_v4 to ($ext_if) port 53 -> 10.215.1.211 port 53
# log (to pflog1)
rdr pass proto {tcp, udp} from $not_jail_nat_v4 to ($ext_if) port 53 tag REDIRINTERNAL -> 10.215.1.211 port 53
rdr pass proto {tcp, udp} from $jail_nat_v4 to ($ext_if) port 53 tag REDIRINTERNAL -> 10.215.1.211 port 53
rdr pass proto {tcp, udp} from $not_jail_nat_v4 to ($ext_if) port 65122 tag REDIRINTERNAL -> 10.215.1.219 port 22
rdr pass proto {tcp, udp} from $jail_nat_v4 to ($ext_if) port 65122 tag REDIRINTERNAL -> 10.215.1.219 port 22
nat pass tagged REDIRINTERNAL -> (jail_nat)
nat pass tagged REDIREXTERNAL -> ($ext_if)
@ -64,6 +69,8 @@ pass quick on $allow
# Single interface kubernetes cluster is working with the following run on mrmanager:
# doas route add -host 74.80.180.139 -interface jail_nat
# doas route add -net 10.129.0.0/16 -interface jail_nat
# ? doas route -6 add -net '2620:11f:7001:7:ffff:ffff:0ad7:0100/120' -interface jail_nat
# ? doas ifconfig jail_nat inet6 2620:11f:7001:7:ffff:ffff:0ad7:0101/120
# doas sysctl net.link.ether.inet.proxyall=1
# Plus this in pf.conf:
# pass quick from any to 74.80.180.139
@ -73,6 +80,10 @@ pass in on jail_nat
# Allow traffic from my machine to the jails/virtual machines
pass out on jail_nat from (jail_nat:network)
#pass quick in on $ext_if proto {tcp6, udp6} from any to 2620:11f:7001:7:ffff:ffff:0ad7:0100/120
pass in quick on $ext_if from any to 2620:11f:7001:7:ffff:ffff:0ad7:0100/120
pass out quick on jail_nat to 2620:11f:7001:7:ffff:ffff:0ad7:0100/120
pass in on $ext_if proto tcp to any port $tcp_pass_in
pass in on $ext_if proto udp to any port $udp_pass_in

View File

@ -1,2 +1,2 @@
# Set screen brightness. Ever since enabling adaptive brightness management, my brightness ends up sinking lower on re-boots (I suspect it is saving the actual brightness rather than the set brightness). This forces the brightness back to the level I prefer.
w- /sys/class/backlight/amdgpu_bl0/brightness - - - - 85
w- /sys/class/backlight/amdgpu_bl0/brightness - - - - 21845

View File

@ -34,7 +34,7 @@
- name: Configure kernel command line
zfs:
name: "zroot/linux"
name: "zroot/linux/archwork/be"
state: present
extra_zfs_properties:
# amdgpu.abmlevel=3 :: Automatically reduce screen brightness but tweak colors to compensate for power reduction.
@ -44,7 +44,7 @@
# amd_pstate=active :: Same as passive except we can set the energy performance preference (EPP) to suggest how much we prefer performance or energy efficiency.
# amd_pstate=guided :: Same as passive except we can set upper and lower frequency bounds.
# amdgpu.dcdebugmask=0x10 :: Allegedly disables Panel Replay from https://community.frame.work/t/tracking-freezing-arch-linux-amd/39495/32
"org.zfsbootmenu:commandline": "rw quiet amdgpu.abmlevel=3 pcie_aspm=force pcie_aspm.policy=powersupersave nowatchdog amdgpu.dcdebugmask=0x10"
"org.zfsbootmenu:commandline": "rw quiet amdgpu.abmlevel=2 pcie_aspm=force pcie_aspm.policy=powersupersave nowatchdog amdgpu.dcdebugmask=0x10"
- name: Install Configuration
copy:

View File

@ -1,27 +1,27 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
mDMEXZwWGhYJKwYBBAHaRw8BAQdAfv7qozKkmf4D+5PDzADsMm4aAKDGLha7+Cu0
0H+RsWG0HlRvbSBBbGV4YW5kZXIgPHdvcmtAZml6ei5idXp6PoiQBBMWCAA4FiEE
uEgVk2PCh3kXlUvhJ95A2bhFXBsFAl+w+R0CGwMFCwkIBwIGFQoJCAsCBBYCAwEC
HgECF4AACgkQJ95A2bhFXBt6fgD+NOYnw9gz5K/q3H5LE/JvqzCSHezJmeGgif0C
uU4m1/MA+gPDKME7syEtJsTpELEMrxWWpDW0tD/W1iJE7roGYPQPtB1Ub20gQWxl
eGFuZGVyIDx0b21AZml6ei5idXp6PoiQBBMWCAA4FiEEuEgVk2PCh3kXlUvhJ95A
2bhFXBsFAl2cFhoCGwMFCwkIBwIGFQgJCgsCBBYCAwECHgECF4AACgkQJ95A2bhF
XBvYJQEA19wc2s/bEKcnHONC3i8UikLFqZXyYoH6/MFjoAteU8sBAKpE7Qq0zbJb
XWRESzK3u6p7/+kUqOeDltAuKXTe1FAGuDMEXZwWyhYJKwYBBAHaRw8BAQdAPyIL
4EGg4T5JO9q2kpVDy2WjMiXz3nZXwYW4GLoTYkiI9QQYFggAJgIbAhYhBLhIFZNj
wod5F5VL4SfeQNm4RVwbBQJlC4ZhBQkLMdaXAIF2IAQZFggAHRYhBIHmRDmWdVAu
sSUWutOhecmlPA7eBQJdnBbKAAoJENOhecmlPA7ejJ4A/iq7N2mMhx+ovOXm1REo
ASPF3l4YAAjOHsXqcPtFHKGJAQCiuA71d6CQ+qNZLuka/KVB/etkkJ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NLm8xYJKwYBBAHaRw8BAQdA
HDhppS6yD8j1Bb/i6ku16uQ3qhshDNA9cOQeMxBae9aI9QQYFggAJhYhBNJyyNYW
fyaFlGdmb0J4KZ+4T2h1BQJo0ubzAhsCBQkDwmcAAIEJEEJ4KZ+4T2h1diAEGRYI
AB0WIQS9v3ap15pUELURqaY2yZ6LPDnYXwUCaNLm8wAKCRA2yZ6LPDnYXyaNAPsF
gR37jEqfgEByVsoKY6bB82T79o9d4FQe1iPsURyuLwD/fkQyV3NwGjysxkoZqYmK
mXJYqtWRBTe2G2UUkm6E/QafHwD+IbkCZ6sGTcexsqzex5x6U8TOvbdVS4dKjSf1
nVRGxvwBAPiIJsXWVuwmskWMDpcaW/qgQ8hOEuq7/vlkZDGOnMgOuDgEaNLnDBIK
KwYBBAGXVQEFAQEHQBcOCDGnrRwv51c5B7QVLMkLC2UKUzPPrahLZHT3RWhmAwEI
B4h+BBgWCAAmFiEE0nLI1hZ/JoWUZ2ZvQngpn7hPaHUFAmjS5wwCGwwFCQPCZwAA
CgkQQngpn7hPaHUZIAD/ZwQ9sLIwuO5qPFAAkqcaNyt68O6WkD8sKaq1r/TPviAA
/j92d7cRUIkJtS8odRYlK51r9eMeTGh2npaO+j3VKCgBuDMEaNLnJRYJKwYBBAHa
Rw8BAQdAPT7jOLbozd5hacityJHniQ6UbHN+AJcb6jh5rXOnOuSIfgQYFggAJhYh
BNJyyNYWfyaFlGdmb0J4KZ+4T2h1BQJo0uclAhsgBQkDwmcAAAoJEEJ4KZ+4T2h1
rREA/3QE6suVUDl4OS2tCi4z2fh/7kjt29I3IFo+/B0AOumgAP0ao8FGqJyFC8YA
7V6T4qrXHbhlqTeofGhQ+iu7HqZVCw==
=OfDR
-----END PGP PUBLIC KEY BLOCK-----

View File

@ -0,0 +1,15 @@
rg {
path = "/jail/${name}";
vnet;
exec.prestart += "/usr/local/bin/jail_netgraph_bridge start jail_nat jail${name} 10.215.1.1/24";
exec.poststop += "sleep 10; /usr/local/bin/jail_netgraph_bridge stop jail_nat jail${name}";
vnet.interface += "jail${name}";
devfs_ruleset = 14;
mount.devfs;
mount.fstab = "/etc/fstab.${name}";
exec.start += "/bin/sh /etc/rc";
exec.stop = "/bin/sh /etc/rc.shutdown jail";
exec.consolelog = "/var/log/jail_${name}_console.log";
}

View File

@ -26,7 +26,7 @@ function by_src {
}
function by_bin {
DESTRELEASE=13.2-RELEASE
DESTRELEASE=14.3-RELEASE
DESTARCH=`uname -m`
SOURCEURL=http://ftp.freebsd.org/pub/FreeBSD/releases/$DESTARCH/$DESTRELEASE/
for component in base ports; do fetch $SOURCEURL/$component.txz -o - | tar -xf - -C "$DESTDIR" ; done

View File

@ -94,7 +94,54 @@
// momlaptop - hard-coded in rc.conf, reproduced here to reserve ip
"hw-address": "06:85:69:c5:6a:d6",
"ip-address": "10.215.1.218"
},
{
// hydra
"hw-address": "06:84:36:68:03:77",
"ip-address": "10.215.1.219"
},
{
// certificate - hard-coded in rc.conf, reproduced here to reserve ip
"hw-address": "06:7b:e0:08:16:5d",
"ip-address": "10.215.1.220"
},
{
// nix controller0 - hard-coded in nix config, reproduced here to reserve ip
// IPv6: 2620:11f:7001:7:ffff:ffff:0ad7:01dd
"hw-address": "06:7b:e0:08:16:01",
"ip-address": "10.215.1.221"
},
{
// nix controller1 - hard-coded in nix config, reproduced here to reserve ip
// IPv6: 2620:11f:7001:7:ffff:ffff:0ad7:01de
"hw-address": "06:7b:e0:08:16:02",
"ip-address": "10.215.1.222"
},
{
// nix controller2 - hard-coded in nix config, reproduced here to reserve ip
// IPv6: 2620:11f:7001:7:ffff:ffff:0ad7:01df
"hw-address": "06:7b:e0:08:16:03",
"ip-address": "10.215.1.223"
},
{
// nix worker0 - hard-coded in nix config, reproduced here to reserve ip
// IPv6: 2620:11f:7001:7:ffff:ffff:0ad7:01e0
"hw-address": "06:7b:e0:08:16:04",
"ip-address": "10.215.1.224"
},
{
// nix worker1 - hard-coded in nix config, reproduced here to reserve ip
// IPv6: 2620:11f:7001:7:ffff:ffff:0ad7:01e1
"hw-address": "06:7b:e0:08:16:05",
"ip-address": "10.215.1.225"
},
{
// nix worker2 - hard-coded in nix config, reproduced here to reserve ip
// IPv6: 2620:11f:7001:7:ffff:ffff:0ad7:01e2
"hw-address": "06:7b:e0:08:16:06",
"ip-address": "10.215.1.226"
}
]
}
],

View File

@ -1,19 +1,3 @@
- name: Build aur packages
register: buildaur
become_user: "{{ build_user.name }}"
command: "aurutils-sync --no-view {{ item }}"
args:
creates: "/var/cache/pacman/custom/{{ item }}-*.pkg.tar.*"
loop:
- nvm
- name: Update cache
when: buildaur.changed
pacman:
name: []
state: present
update_cache: true
- name: Install packages
package:
name:

View File

@ -1,3 +1,11 @@
profile office {
output eDP-1 disable
output "Dell Inc. DELL C2722DE 6PH6T83" enable
}
profile office2 {
output eDP-1 disable
output "BOE 0x0BCA Unknown" enable
}
profile docked {
output eDP-1 disable
output "Dell Inc. DELL U3014 P1V6N35M329L" enable

View File

@ -1 +1,4 @@
nfs_server_enable="YES"
# nfsv4_server_enable="YES"
# nfsv4_server_only="YES"
nfs_server_flags="-u -t --minthreads 1 --maxthreads 32"

View File

@ -8,37 +8,37 @@
- name: net.link.ether.inet.proxyall
value: "1"
- name: Install service configuration
copy:
src: "files/{{ item }}_rc.conf"
dest: "/etc/rc.conf.d/{{ item }}"
mode: 0644
owner: root
group: wheel
loop:
- nfsd
- mountd
- lockd
- statd
- rpcbind
# - name: Install service configuration
# copy:
# src: "files/{{ item }}_rc.conf"
# dest: "/etc/rc.conf.d/{{ item }}"
# mode: 0644
# owner: root
# group: wheel
# loop:
# - nfsd
# - mountd
# - lockd
# - statd
# - rpcbind
- name: Create zfs datasets
zfs:
name: zdata/k8spersistent
state: present
extra_zfs_properties:
sharenfs: "-network 10.215.1.0/24,-alldirs,-maproot=root:root"
mountpoint: /k8spersistent
# - name: Create zfs datasets
# zfs:
# name: zdata/k8spersistent
# state: present
# extra_zfs_properties:
# sharenfs: "-network 10.215.1.0/24,-alldirs,-maproot=root:root"
# mountpoint: /k8spersistent
- name: Update ownership
file:
name: "{{ item }}"
state: directory
mode: 0777
owner: root
group: wheel
loop:
- /k8spersistent
# - name: Update ownership
# file:
# name: "{{ item }}"
# state: directory
# mode: 0777
# owner: root
# group: wheel
# loop:
# - /k8spersistent
- name: Install scripts
copy:

View File

@ -0,0 +1 @@
# foo: []

View File

View File

@ -0,0 +1,14 @@
# - name: restart foo freebsd
# when: 'os_flavor == "freebsd"'
# listen: restart foo
# service:
# name: foo
# state: restarted
# - name: restart ssh linux
# when: 'os_flavor == "linux"'
# listen: restart foo
# systemd:
# state: restarted
# name: foo
# daemon_reload: yes

View File

@ -0,0 +1,2 @@
# dependencies:
# - users

View File

@ -0,0 +1,55 @@
# - name: Create directories
# file:
# name: "{{ item }}"
# state: directory
# mode: 0755
# owner: root
# group: wheel
# loop:
# - /foo/bar
# - name: Install scripts
# copy:
# src: "files/{{ item.src }}"
# dest: "{{ item.dest }}"
# mode: 0755
# owner: root
# group: wheel
# loop:
# - src: foo.bash
# dest: /usr/local/bin/foo
# - name: Install Configuration
# copy:
# src: "files/{{ item.src }}"
# dest: "{{ item.dest }}"
# mode: 0600
# owner: root
# group: wheel
# loop:
# - src: foo.conf
# dest: /usr/local/etc/foo.conf
# - name: Clone Source
# git:
# repo: "https://foo.bar/baz.git"
# dest: /foo/bar
# version: "v1.0.2"
# force: true
# diff: false
- import_tasks: tasks/freebsd.yaml
when: 'os_flavor == "freebsd"'
- import_tasks: tasks/linux.yaml
when: 'os_flavor == "linux"'
- include_tasks:
file: tasks/peruser.yaml
apply:
become: yes
become_user: "{{ initialize_user }}"
when: users is defined
loop: "{{ users | dict2items | community.general.json_query('[?value.initialize==`true`].key') }}"
loop_control:
loop_var: initialize_user

View File

@ -0,0 +1,15 @@
- name: Install packages
package:
name:
- ndproxy
state: present
- name: Install service configuration
copy:
src: "files/{{ item }}_rc.conf"
dest: "/etc/rc.conf.d/{{ item }}"
mode: 0644
owner: root
group: wheel
loop:
- ndproxy

View File

@ -0,0 +1,29 @@
# - name: Build aur packages
# register: buildaur
# become_user: "{{ build_user.name }}"
# command: "aurutils-sync --no-view {{ item }}"
# args:
# creates: "/var/cache/pacman/custom/{{ item }}-*.pkg.tar.*"
# loop:
# - foo
# - name: Update cache
# when: buildaur.changed
# pacman:
# name: []
# state: present
# update_cache: true
# - name: Install packages
# package:
# name:
# - foo
# state: present
# - name: Enable services
# systemd:
# enabled: yes
# name: "{{ item }}"
# daemon_reload: yes
# loop:
# - foo.service

View File

@ -0,0 +1,2 @@
- import_tasks: tasks/common.yaml
# when: foo is defined

View File

@ -0,0 +1,29 @@
- include_role:
name: per_user
# - name: Create directories
# file:
# name: "{{ account_homedir.stdout }}/{{ item }}"
# state: directory
# mode: 0700
# owner: "{{ account_name.stdout }}"
# group: "{{ group_name.stdout }}"
# loop:
# - ".config/foo"
# - name: Copy files
# copy:
# src: "files/{{ item.src }}"
# dest: "{{ account_homedir.stdout }}/{{ item.dest }}"
# mode: 0600
# owner: "{{ account_name.stdout }}"
# group: "{{ group_name.stdout }}"
# loop:
# - src: foo.conf
# dest: .config/foo/foo.conf
- import_tasks: tasks/peruser_freebsd.yaml
when: 'os_flavor == "freebsd"'
- import_tasks: tasks/peruser_linux.yaml
when: 'os_flavor == "linux"'

View File

@ -1,6 +1,11 @@
[General]
EnableNetworkConfiguration=true
# AddressRandomization=network
[DriverQuirks]
PowerSaveDisable=*
# Needed for Qualcomm WCN785x
ControlPortOverNL80211=false
[General]
AddressRandomization=network
EnableNetworkConfiguration=true
[Rank]
BandModifier2_4GHz=1.000000
BandModifier5GHz=1.000000
BandModifier6GHz=0.000000

View File

@ -1,2 +1,2 @@
[options]
IgnorePkg = linux linux-headers
IgnorePkg = linux linux-headers chromium

View File

@ -81,12 +81,6 @@ Include = /etc/pacman.d/mirrorlist
[extra]
Include = /etc/pacman.d/mirrorlist
#[community-testing]
#Include = /etc/pacman.d/mirrorlist
[community]
Include = /etc/pacman.d/mirrorlist
# If you want to run 32 bit applications on your x86_64 system,
# enable the multilib repositories as required here.

View File

@ -23,6 +23,9 @@ $ORIGIN fizz.buzz.
; Allows receivers to know you send your mail via Fastmail, and other servers
IN TXT v=spf1 include:spf.messagingengine.com ?all
; Tell receivers what to do with fake email
_dmarc IN TXT "v=DMARC1; p=none; rua=mailto:postmaster@fizz.buzz;"
ns1 IN A 74.80.180.138
ns2 IN A 74.80.180.138

View File

@ -1 +1 @@
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGu+k5lrirokdW5zVdRVBOqEOAvAPlIkG/MdJNc9g5ky cardno:000611194908
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAID0+4zi26M3eYWnIrciR54kOlGxzfgCXG+o4ea1zpzrk openpgp:0x7FF123C8

View File

@ -23,6 +23,7 @@ set $menu wofi --show drun --gtk-dark
# Do not show a title bar on windows
default_border pixel 2
hide_edge_borders smart_no_gaps
bindsym $mod+grave exec $term

View File

@ -5,6 +5,6 @@ set -euo pipefail
IFS=$'\n\t'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
makoctl set-mode do-not-disturb
makoctl mode -s do-not-disturb
swaymsg output "'Dell Inc. DELL U3014 P1V6N35M329L'" scale 2

View File

@ -5,6 +5,6 @@ set -euo pipefail
IFS=$'\n\t'
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
makoctl set-mode default
makoctl mode -s default
swaymsg output "'Dell Inc. DELL U3014 P1V6N35M329L'" scale 1

View File

@ -5,7 +5,7 @@
args:
creates: "/var/cache/pacman/custom/{{ item }}-*.pkg.tar.*"
loop:
- wlvncc-git
# - wlvncc-git
- wl-screenrec-git
- name: Update cache
@ -23,7 +23,7 @@
- xorg-xeyes
- xorg-xwayland
- rofimoji
- wlvncc-git
# - wlvncc-git
- wl-screenrec-git # screen recording
- name: Install scripts

View File

@ -20,6 +20,12 @@
"command": "-workbench.action.navigateBack",
"when": "canNavigateBack"
},
{
// This isn't quite right. In emacs it would go back to the last location you performed an action which could include navigation. This goes back to the place where you last changed the text. Either way, close enough.
"key": "ctrl+x ctrl+x",
"command": "workbench.action.navigateToLastEditLocation",
"when": "canNavigateToLastEditLocation"
},
{
"key": "shift+alt+/",
"command": "editor.action.goToReferences",
@ -276,5 +282,15 @@
{
"key": "ctrl+k ctrl+p",
"command": "-workbench.action.showAllEditors"
},
{
"key": "shift+enter",
"command": "-python.execInREPL",
"when": "config.python.REPL.sendToNativeREPL && editorTextFocus && !isCompositeNotebook && !jupyter.ownsSelection && !notebookEditorFocused && editorLangId == 'python'"
},
{
"key": "shift+enter",
"command": "-python.execSelectionInTerminal",
"when": "editorTextFocus && !findInputFocussed && !isCompositeNotebook && !jupyter.ownsSelection && !notebookEditorFocused && !replaceInputFocussed && editorLangId == 'python'"
}
]

View File

@ -18,6 +18,7 @@
"workbench.editor.showTabs": "none",
"workbench.activityBar.location": "hidden",
"window.menuBarVisibility": "toggle",
"window.commandCenter": false,
"explorer.autoReveal": false,
"[python]": {
"editor.defaultFormatter": "ms-python.black-formatter",
@ -31,11 +32,26 @@
"editor.defaultFormatter": "hashicorp.terraform",
"editor.formatOnSave": true
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[typescriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"javascript.autoClosingTags": false,
"typescript.autoClosingTags": false,
"black-formatter.importStrategy": "fromEnvironment",
"workbench.statusBar.visible": false,
"git.openRepositoryInParentFolders": "never",
"files.autoSave": "afterDelay",
"editor.rulers": [
100
]
],
"workbench.secondarySideBar.defaultVisibility": "hidden",
"editor.autoClosingBrackets": "never",
"editor.autoSurround": "never",
"workbench.editor.navigationScope": "editorGroup",
"python.analysis.typeCheckingMode": "standard"
}

View File

@ -27,7 +27,8 @@
args:
creates: "/var/cache/pacman/custom/{{ item }}-*.pkg.tar.*"
loop:
- zfs-dkms-git
# - zfs-dkms-git
- zfs-dkms
- zfs-utils
- name: Update cache
@ -40,7 +41,8 @@
- name: Install packages
package:
name:
- zfs-dkms-git
# - zfs-dkms-git
- zfs-dkms
- zfs-utils
state: present

View File

@ -78,6 +78,8 @@ function start_vm {
-D \
-c 2 \
-m 3G \
-H \
-S \
-o 'rtc.use_localtime=false' \
-s 0,hostbridge \
-s "4,nvme,/dev/zvol/zroot/vm/mediamtx/disk0" \

View File

@ -76,6 +76,7 @@ function start_vm {
-c 4 \
-m 8G \
-H \
-S \
-o 'rtc.use_localtime=false' \
-s 0,hostbridge \
-s "4,nvme,/dev/zvol/zroot/vm/opnsense/disk0" \

View File

@ -78,6 +78,7 @@ function start_vm {
-c 1 \
-m 3G \
-H \
-S \
-o 'rtc.use_localtime=false' \
-s 0,hostbridge \
-s "4,nvme,/dev/zvol/zroot/vm/unifi/disk0" \