1

I am working with the yocto project and a Raspberry Pi 0 with wifi. I want to integrate the wpa_supplicant.conf file and copy it to the /etc/ folder. My recipe fails with reason stating that I don't have permission to copy this file at this location.

I am using do_install_append, but it did not work

do_install_append() { install -m 0755 ${S}/wpa_supplicant.conf /etc/ install -m 0755 ${S}/interaces /etc/network/ }

I tried copy -f but it failed also, nevertheless I tried sudo, but no clue.

tlhIngan
  • 3,372
  • 5
  • 21
  • 33

2 Answers2

1

Just put your wpa_supplicant.conf file directly on the root of the /boot partition of your SD-card.

The Pi will move it to the right location and start using it.

This overwrites your old config, so do a backup first.

I usually put the wpa_supplicant.conf there immediately after writing the image to the card. I usually put an empty file named ssh there too, and that enables SSH.

That way it connects to WiFi on first boot with SSH enabled.

The /boot partition is the one formatted as vfat/fat/fat32.

svin83
  • 295
  • 2
  • 9
0

Solved by creating a folder first for the etc and then for the network

using the following install -d ${D}/etc install -d ${D}/etc/network