This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
zpool export -a | |
zpool import -N -R /mnt rpool | |
zpool import -N -R /mnt bpool | |
# skipping first rpool/ROOT and initial root (i.e. rpool/ROOT/ubuntu), because doesn't have tailing '/' so grabs numbers | |
zfs list | grep ROOT | tail -n+3 | |
zfs mount rpool/ROOT/ubuntu | |
zfs mount -a | |
mount --rbind /dev /mnt/dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
## run all commands by doing | |
# curl -fsSL 'https://git.io/Je0e6' | sudo bash | |
## running mount commands | |
curl -fsSL 'https://git.io/Je0eX' | sudo bash | |
## running umount commands | |
# get out of chroot |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$socket = new-object System.Net.Sockets.TcpClient('127.0.0.1', 413); | |
if($socket -eq $null){exit 1} | |
$stream = $socket.GetStream(); | |
$writer = new-object System.IO.StreamWriter($stream); | |
$buffer = new-object System.Byte[] 1024; | |
$encoding = new-object System.Text.AsciiEncoding; | |
do | |
{ | |
$writer.Flush(); | |
$read = $null; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -euo pipefail | |
# set -x | |
if [[ $# -ne 1 ]] ; then | |
printf "Please pass at least 1 arguments: %s\n" "path to samurai src folder" | |
exit 1 | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://computingforgeeks.com/how-to-enable-and-use-ssh-x11-forwarding-on-vagrant-instances/ | |
# used in https://github.com/elreydetoda/vagrant-files/ | |
config.ssh.forward_agent = true | |
config.ssh.forward_x11 = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/elreydetoda/vagrant-files/tree/master/bento_ubuntu-18.04 | |
Vagrant.configure("2") do |config| | |
config.vm.box = "bento/ubuntu-18.04" | |
config.ssh.forward_agent = true | |
config.ssh.forward_x11 = true | |
config.vm.provision "shell", inline: <<-SHELL | |
apt-get update | |
apt-get install -y xauth | |
SHELL | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -exuo pipefail | |
################################################## | |
### Variables | |
## apt | |
apt_repos=( | |
'ppa:kgilmer/regolith-stable' # https://blog.elreydetoda.site/minimal-i3-gaps-install-ubuntu/ | |
'ppa:linuxuprising/shutter' # awesome screenshotting software |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Get-OUPermissions{ | |
<# | |
.SYNOPSIS | |
FindOuPermissions is a Windows PowerShell script that finds all of the different OUs in a domain, | |
determins the permissions assigned to different users and groups, and reports back which are different | |
from their parent; including what those permissions are. | |
This script does require that the device be joined to the domain being queried and RSAT is installed. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -${-//[s]/}eu${DEBUG+xv}o pipefail | |
season=( | |
'Spring' | |
'Summer' | |
'Fall' | |
'Autumn' | |
'Winter' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: localhost | |
tasks: | |
- name: Linux | Find all versions of Vagrant | |
uri: | |
url: https://releases.hashicorp.com/vagrant/index.json | |
return_content: yes | |
register: vagrant_index | |
# this was the original code from here: https://github.com/diodonfrost/ansible-role-vagrant/blob/master/tasks/setup-Linux.yml#L14 |