Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Setting up ssh and wifi on first Raspbian Strech Lite boot

Raspbian Strech Lite Quick setup

In order to enable SSH and wifi on first boot we need to add two files to the root folder on the SD card before inserting it into the raspberry.

First, create an empty file named ssh. Then, create a second file called wpa_supplicant.conf. The contents of this file should be

country=US
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1

followed by the result of the command wpa_passphrase [WIFI-NAME] [PASSWORD].

For example:

$ cat wpa_supplicant.conf
country=US
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
        ssid="yourwifi"
        psk=5b203d29asd5asd9caf383e6499d34291a25b462e83c2f1584d70101ff56c96
}

Now eject the SD card from your computer, insert it into the raspberry and 💥!

@caike

This comment has been minimized.

Copy link
Owner Author

caike commented Oct 9, 2017

In case you don't have access to a Linux machine in order to run wpa_passphrase, see https://github.com/caike/supplicant-psk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.