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
| if [ ! -e "/run/udev/" ]; then | |
| sudo mkdir /run/udev | |
| sudo service udev start & | |
| fi |
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
| dism /online /cleanup-image /startcomponentcleanup |
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
| # Get access token, valid for 1 hour | |
| ACCESS_TOKEN=$(./get-access-token.sh Credentials.json "https://www.googleapis.com/auth/drive https://www.googleapis.com/auth/spreadsheets") | |
| # Find template id | |
| TEMPLATE_ID=$(curl -G -H "Authorization: Bearer $ACCESS_TOKEN" \ | |
| --data-urlencode "q=mimeType contains 'spreadsheet' and name='Landet Template'" \ | |
| "https://www.googleapis.com/drive/v3/files" | jq -r .files[0].id) | |
| # Find file id, None if not there | |
| FILE_ID=$(curl -G -H "Authorization: Bearer $ACCESS_TOKEN" \ |
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
| Download factory.img.gz | |
| Use rufus to write to sdcard | |
| Use gparted (virtualbox) to extend root fs to full size of sd-card (this is easiest method) | |
| Use gparted to check the partition (this is required, RPi will not boot otherwise) | |
| Use gparted terminal | |
| mount /dev/sdb1 /media -o rw | |
| lsblk -o NAME,PARTUUID,UUID | |
| edit boot partition cmdline.txt for PARTUUID might change after gparted. | |
| sudo vi cmdline.txt | |
| --------- |