Headless Wifi setup on the Raspberry Pi

If you are looking to have a headless Raspberry Pi setup that you can get configured 100% remotely right after you plug it in you will want to make sure it joins the proper Wifi after the first boot if you are not connecting directly to ethernet.

To get started once you have an SD card with the newest Raspbian OS installed on it, you will want to create the wpa_supplicant.conf file on the /boot partition of the SD card. Add the following information to the file. (Swap out for the proper SSID and Wifi Password)

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=US
     
network={
    ssid="SSID"
    psk="PASSWORD"
    scan_ssid=1
}

Save the file, eject the SD card and you should now be able to boot the Raspberry Pi and have it automatically join your Wifi! Now if you have a Ubiquiti network setup where the device is connecting then you will be able to track it down quite easy from the Unifi controller software.