Skip to content

Instantly share code, notes, and snippets.

View agent-squirrel's full-sized avatar

Adam Heathcote agent-squirrel

View GitHub Profile
@agent-squirrel
agent-squirrel / Velvet_OS_Bookworm_Install_KRANE.txt
Created May 4, 2025 12:30
Velvet_OS_Bookworm_Install_KRANE
This file has been truncated, but you can view the full file.
[info] unmounting all partitions of target
[info] wipe partition table
GPT data structures destroyed! You may now partition the disk using fdisk or
other utilities.
Creating new GPT entries in memory.
The operation has completed successfully.
[info] create a new one
[info] create kernel Partitions
[info] create other partitions
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
@agent-squirrel
agent-squirrel / eprints_migration.sh
Created November 24, 2022 23:28
Figshare Migration
#!/bin/bash
#######################################
# #
#Eprints to Figshare migration script #
#Adam Heathcote - 2022 #
# #
#######################################
### Gen creds ###
# The hostname within the docker network
# Or whatever host your outpost is on
ldap_server: ak-outpost-ldap
ldap_port: 3389
Secure_LDAP: false
StartTLS: false
skip_ssl: true
@agent-squirrel
agent-squirrel / per_domain.ps1
Created April 25, 2022 05:08
Per domain DNS servers Windows
Add-DnsClientNrptRule -Namespace ".asgard.local" -NameServers "10.0.1.1"
#!/bin/bash
sudo docker stop ubnt-speedtest
sudo docker stop ubnt-speedtest-watchtower
sudo docker rm ubnt-speedtest
sudo docker rm ubnt-speedtest-watchtower
printf "y\n" | sudo docker system prune
curl -fsSL https://sp-dir.uwn.com/api/v1/install?t=183bb99c-17ae-4a26-b784-7e60f1a60d47 > /tmp/speed_inst.sh && sudo bash /tmp/speed_inst.sh
#!/bin/bash
echo "Installing Docker + Docker Compose via official repos"
echo
echo "Update sources"
sudo apt update
sudo apt install ca-certificates curl gnupg lsb-release -y
echo
echo "Grab GPG key"
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
@agent-squirrel
agent-squirrel / config.php
Created July 3, 2021 07:16
LibreNMS FreeIPA LDAP Authentication
#At Launtel we authenticate users to our NOC systems via FreeIPA.
#Pieceing together the various snippets on the internet to get LibreNMS to talk LDAP to the IPA server was a nightmare,
#so here I save you the hassle.
#ipausers can read everything
#nocadmins can write everything
# LDAP
$config['auth_mechanism'] = 'ldap';
$config['auth_ldap_debug'] = false;
$config['auth_ldap_server'] = 'ldap://servername.fqdn';
#!/bin/bash
#Check for super user
if [ "$EUID" -ne 0 ]
then echo 'This script can only be run as the super user.
Try rerunning with sudo.'
[[ "$0" = "$BASH_SOURCE" ]] && exit 1 || return 1
fi
clear