File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -176,7 +176,13 @@ addtask do_deploy_boot_chain before do_deploy
176176def __do_deploy_boot (d ):
177177
178178 if d . getVar ('IB_STORAGE_MODE' ) not in ("remote" , "http" ):
179- bb . warn ("Now mounting" )
179+ # Make deploy depend on an initialised storage. In "soft" mode this
180+ # creates sdcard.img.<platform> on the fly when it is missing (the
181+ # same work as scripts/init_storage.sh), so a fresh tree can deploy
182+ # without a separate manual init step. deploy.sh already opened a
183+ # sudo session, so the losetup/mkfs done here via `sudo -n` succeeds.
184+ __do_fs_check (d )
185+ bb . plain ("Mounting storage" )
180186 __do_fs_mount (d )
181187
182188 __do_platform_deploy (d )
Original file line number Diff line number Diff line change @@ -169,7 +169,13 @@ def __do_fs_mount(d):
169169 os . stat (img_path )
170170 except OSError as e :
171171 if e . errno == errno . ENOENT :
172- bb . fatal (f "{img_path} does not exist" )
172+ bb . fatal (
173+ f "Storage image '{img_path}' does not exist: the filesystem "
174+ f "for platform '{IB_PLATFORM}' has not been initialised yet.\n"
175+ f "Deploy normally creates it automatically; if you reach this, "
176+ f "initialise the storage explicitly by running:\n"
177+ f " ./scripts/init_storage.sh\n"
178+ f "then run the deploy again." )
173179
174180 p1 = os . path . join (WORKDIR , "p1" )
175181 p2 = os . path . join (WORKDIR , "p2" )
You can’t perform that action at this time.
0 commit comments