Advanced Search
Search Results
29 total results found
Quick Git Commands
Remove merged branches git branch --merged origin/main | rg -v "main" | xargs git branch -d Make sure to test the first command before running the whole line, you don't want to accidentally delete your main branch Prune local branches that are deleted on th...
systemd Shell Execution
To start a shell with the same environment as a particular systemd service sudo systemd-run --property=EnvironmentFile=<path/to/env/file> --uid=<service user> --pty bash Be sure to use ^] instead of exiting the shell directly - this command spawns a servic...
User Provisioning
Perform these following steps: pveum useradd etorres@pam pveum group add wheel -comment 'System admins' pveum acl modify / -group wheel -role Administrator pveum acl modify / -group wheel -role PVEAdmin pveum acl modify / -group wheel -role PVEVMAdmin pv...
Terraform Setup
Creating the Terraform role in PVE # pveum user add terraform@pve # pveum role add Terraform -privs "Realm.AllocateUser, VM.PowerMgmt, VM.GuestAgent.Unrestricted, Sys.Console, Sys.Audit, Sys.AccessNetwork, VM.Config.Cloudinit, VM.Replicate, Pool.Allocate, S...
Comin Hard Reset
Do not use git push --force on main, otherwise comin will not be able to recognize changes until it is reset # rm -rf /var/lib/comin # systemctl restart comin # cd /var/lib/comin/repository # comin fetch
Provisioning a new nixOS Host
nix run nixos-anywhere -- --flake '.#<host>' --generate-hardware-config nixos-generate-config ./hosts/<host>/hardware-configuration.nix nixos@<ip>
/etc/network/interfaces
# network interface settings; autogenerated # Please do NOT modify this file directly, unless you know what # you're doing. # # If you want to manage parts of the network configuration manually, # please utilize the 'source' or 'source-directory' directives to...
home-manager setup
nix run home-manager -- switch --flake '.#<config>'
Adding a new host for ssh on Linux/KDE
Sometimes, when adding a new ssh host, you get this error: etorres@host.local: Permission denied (publickey,keyboard-interactive). Run this command before attempting SSH: SSH_ASKPASS=/usr/bin/ksshaskpass ssh-add ~/.ssh/key Make sure there are no saved entrie...
/nix/store
List top storage users of files in the nix store nix path-info -rS /run/current-system | sort -nk2 | tail -20 | numfmt --field=2 --to=iec --suffix=B
Setting User Admin Role
# See existing roles pveum role list # Give your user Sys.Modify on the node (grants network editing, among other things) pveum acl modify /nodes/<nodename> -user etorres@pam -role Administrator