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
resource "azurerm_virtual_network" "sec510_cloudwars" { | |
name = "sec510-cloudwars" | |
resource_group_name = azurerm_resource_group.cloudwars.name | |
location = azurerm_resource_group.cloudwars.location | |
address_space = ["10.10.0.0/16"] | |
} | |
resource "azurerm_subnet" "sec510_cloudwars" { | |
name = "sec510-cloudwars-private" |
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
# Add the Repo | |
sudo apt-get update | |
sudo apt-get install -y apt-transport-https ca-certificates curl gnupg lsb-release | |
# Add Docker's GPG Key | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg | |
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null | |
# Set up Docker CE | |
sudo apt-get update |
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
#!/bin/bash | |
# https://docs.rapid7.com/metasploit/installing-the-metasploit-framework/ | |
# TODO Run as Root Check | |
apt-get update | |
curl https://raw.githubusercontent.com/rapid7/metasploit-omnibus/master/config/templates/metasploit-framework-wrappers/msfupdate.erb > msfinstall && chmod 755 msfinstall && ./msfinstall | |
cd ~ | |
wget https://raw.githubusercontent.com/danielmiessler/SecLists/master/Passwords/Common-Credentials/500-worst-passwords.txt |
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
## Supply this file as the user data when launching an Ubuntu EC2 instance | |
#!/bin/bash | |
apt -y update | |
DEBIAN_FRONTEND=noninteractive apt -y upgrade | |
apt install -y ubuntu-mate-desktop | |
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb | |
dpkg -i google-chrome-stable_current_amd64.deb | |
apt install -y xrdp | |
systemctl enable xrdp |