This file contains hidden or 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
| systemctl disable apparmor | |
| systemctl disable ufw | |
| apt-get update && apt-get -y upgrade | |
| apt-get install snmp ntpdate bind9utils wget curl nmap python-scapy thc-ipv6 yersinia hydra tftpd-hpa tftp-hpa tshark quagga vim john freeradius freeradius-utils scrypt easy-rsa cdpr lldpd ladvd radvd hping3 arp-scan snimpy yasat snmp-mibs-downloader stunnel4 telnet openvpn htop dsniff mc | |
| for x in quagga ladvd radvd openvpn freeradius ; do | |
| systemctl stop $x | |
| #systemctl disable $x | |
| #systemctl status $x | |
| done |
This file contains hidden or 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
| # | |
| #Set VM Name, Switch Name, and Installation Media Path. | |
| $VMname = 'TESTVM' | |
| #$Switch = 'NatSwitch' | |
| $Switch = 'VmNAT' | |
| $ISO = 'C:\Users\Administrator\Downloads\14393.0.160715-1616.RS1_RELEASE_SERVER_EVAL_X64FRE_EN-US.ISO' | |
| $VHD = 'C:\Users\Administrator\Documents\' | |
| $VHDSize = 40 GB | |
| $RAM = 4 GB |
This file contains hidden or 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
| # | |
| $VMname = 'TESTVM' | |
| GET-VM –Name $VMname | GET-VMHardDiskDrive | Foreach { STOP-VM –Name $_.VMname; Remove-item –path $_.Path; REMOVE-VM –Name $_.VMname -Force } |
This file contains hidden or 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
| #!/bin/bash | |
| connection="System eth0" | |
| ip4="192.168.168" | |
| ip6="fd00:168:168" | |
| 1_interfaces () { | |
| hostnamectl set-hostname router | |
| nmcli c mod "$connection" ipv4.addresses $ip4.1/24 | |
| nmcli c mod "$connection" ipv4.method manual | |
| nmcli c mod "$connection" ipv6.addresses $ip6::1/64 | |
| nmcli c mod "$connection" ipv6.method manual |
This file contains hidden or 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
| #### Contents of the preconfiguration file (for wheezy) | |
| ### Localization | |
| d-i debian-installer/locale string en_US.UTF-8 | |
| d-i debian-installer/keymap select us | |
| d-i keymap select us | |
| ### Network configuration | |
| d-i netcfg/choose_interface select auto | |
| ### Mirror settings |
This file contains hidden or 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
| #### Contents of the preconfiguration file (for jessie) | |
| ### Localization | |
| # Preseeding only locale sets language, country and locale. | |
| d-i debian-installer/locale string en_US | |
| # The values can also be preseeded individually for greater flexibility. | |
| #d-i debian-installer/language string en | |
| #d-i debian-installer/country string NL | |
| #d-i debian-installer/locale string en_GB.UTF-8 | |
| # Optionally specify additional locales to be generated. |
This file contains hidden or 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
| #!/bin/bash | |
| if [[ $# == 0 ]]; then | |
| echo Usage: | |
| echo "virt <command> <vm> args" | |
| echo Command is: ip, ssh, scp, sshfs | |
| exit 1 | |
| fi | |
| cmd="$1"; shift |
This file contains hidden or 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
| #!/bin/bash | |
| #================================================================ | |
| # Let's Encrypt renewal script for Apache on Ubuntu/Debian | |
| # @author Erika Heidi<erika@do.co> | |
| # Usage: ./le-renew.sh [base-domain-name] | |
| # More info: http://do.co/1mbVihI | |
| #================================================================ | |
| domain=$1 | |
| le_path='/opt/letsencrypt' | |
| le_conf='/etc/letsencrypt' |
This file contains hidden or 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
| #!/bin/bash | |
| #================================================================ | |
| # Let's Encrypt renewal script for Apache on CentOS | |
| # @author Erika Heidi<erika@do.co> | |
| # Usage: ./le-renew.sh [base-domain-name] | |
| # More info: http://do.co/1SHe4eL | |
| #================================================================ | |
| domain=$1 | |
| le_path='/opt/letsencrypt' | |
| le_conf='/etc/letsencrypt' |
This file contains hidden or 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
| #!/bin/bash | |
| # Variables | |
| guest=$1 | |
| disk=/var/lib/libvirt/images/$2.img | |
| # Create 4G Spare Disk with dd | |
| dd if=/dev/zero of=$disk bs=1M seek=4096 count=0 | |
| # Or create a qcow2 disk | |
| qemu-img create -f qcow2 -o preallocation=metadata $disk 4G |