This is an install script to prepare a raspbian-lite image and configure your Raspberry Pi 3 as a hotspot.
$ wget https://downloads.raspberrypi.org/raspbian_lite_latest
$ unzip raspbian_lite_latest
$ df -h
if your sdcard is mounted
$ sudo umount /dev/sdX
$ sudo dd if=/dev/zero of=/dev/sdX bs=1M count=8
$ sudo dd bs=4M if=*raspbian-*-lite.img of=/dev/sdX
$ sudo mount -v -o offset=70254592 -t ext4 /dev/sdX ./root
If offset
does not match, you can get it with this command :
$ sudo fdisk -l /dev/sdX
It should return something like that :
Device Boot Start End Sectors Size Id Type
/dev/sdX1 8192 137215 129024 63M c W95 FAT32 (LBA)
/dev/sdX2 137216 2709503 2572288 1,2G 83 Linux
So offset=512*137216
.
Edit SSID and password in config/hostapd.conf
Optionally you may also edit IPs in config/interfaces
and config/dnsmasq.conf
Put your openvpn server conf in config/openvpn-server.conf
Put your username and password in config/openvpn-server.auth
$ sh start.sh
To re-mapping the keyboard give the two letter code for your country as argument :
$ sh start.sh fr
$ sudo umount ./root