Assumptions on the setup:
- Router 1 (Main): Handles DHCP and Routing.
- Router 2 (Dumb AP): Uplink cable is in Port 1. CPU is Port 6.
- VLAN 1: Management / Home Network (Untagged on wire).
- VLAN 5: Guest Network (Tagged on wire).
| #!/bin/bash | |
| if [ "$EUID" -ne 0 ]; then | |
| echo "Please run as root" | |
| exit | |
| fi | |
| read -p 'Username: ' user | |
| read -p "ssh Public key for $user: " userpub | |
| echo "The rest of the details will now be taken care of the program" | |
| read -p 'Continue? [Y/n]: ' usercont |