Last active
April 28, 2018 13:25
-
-
Save TravisMullen/ffd49e4d4d3b4663d6769afc77b9d319 to your computer and use it in GitHub Desktop.
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
sudo -E bash -c 'wpa_passphrase $YOUR_WIFI_NAME >> /etc/wpa_supplicant/wpa_supplicant.conf' | |
# enter your password into the prompt | |
/sbin/wpa_supplicant -B -c /etc/wpa_supplicant/wpa_supplicant.conf -i $YOUR_WIFI_DEVICE | |
/sbin/dhclient $YOUR_WIFI_DEVICE |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Using either DHCP or a static config (doesn't matter which)--AND assuming your wifi worked during install--make your /etc/network/interfaces look something like below (for wlan0 should match the name of your wifi card listed under ifconfig -a e.g. your detected wifi card could be nicknamed eth1 by the OS for all I know.):
To configure wpa_supplicant use the command (Referenced in the config above)
Next, create a new executable script named iwconfig (you can name this script anything really, "iwconfig-default-ssid", perhaps?--I just made it short for the example):
Now edit /etc/network/if-up.d/iwconfig and add the SSID you want Ubuntu Server to connect to on startup:
Now bring ifdown (if you haven't already), then ifup, and you should be golden now and when you reboot (as long as you're near your SSID.)