Page 1 of 1

new directory from module? [solved]

Posted: 21 Mar 2018, 20:25
by pfisher
I have a module containing a directory with dozens of files for a local site. When the kiosk iso runs, those files end up extracting to the root level, loose. Is there a way to make my module simply implement a folder (anywhere, so long as it is predictable and can be set to homepage)? Otherwise, would I need to have a script run at start to create a directory and then copy all the files into it (ugh)? That seems like it would take too long each startup. In other words, I am hoping:

some_module.xzm
|-->directory
|---->files

can extract somewhere predictable and retain that structure so "homepage" looks for /directory/files as below

root
|-->same directory name
|---->same directory files

I've seen posts about it but the closest I've come is all the files loose at the root level, as mentioned.

new directory from module?

Posted: 21 Mar 2018, 23:22
by Ed_P
How did you make module.xzm? What commands did you use?

new directory from module?

Posted: 22 Mar 2018, 16:33
by pfisher
Hi. I used the prescribed method of

mksquashfs /(from location)/* /(to location)/xzm/05-website.xzm -comp xz -b 256K -Xbcj x86 -noappend

Thank you

new directory from module?

Posted: 22 Mar 2018, 16:56
by pfisher
You asking the question made me dig further and I did find the option for mksquashfs of "keep-as-directory". I suspect you may have been getting at that, so I will try it and update this thread.

new directory from module?

Posted: 22 Mar 2018, 17:21
by fanthom
You need to run the mksquashfs command against the top folder and not the files inside the folder.
Top folder wont be included in the module.

Thanks

new directory from module?

Posted: 22 Mar 2018, 17:28
by Ed_P
pfisher wrote:
22 Mar 2018, 16:56
I suspect you may have been getting at that,
:D Actually I was thinking of a fanthom command called dir2xzm. But the same command and options are used in it. :happy62:

new directory from module?

Posted: 23 Mar 2018, 12:25
by pfisher
fanthom wrote:
22 Mar 2018, 17:21
You need to run the mksquashfs command against the top folder and not the files inside the folder.
Top folder wont be included in the module.

Thanks
I used the same mksquashfs command as mentioned earlier, but without the /* in order to do it against the top folder. It produced the same result. I will try the keep-as-directory option next and report back. Thanks for your time!

new directory from module?

Posted: 23 Mar 2018, 14:28
by pfisher
Using keep-as-directory worked as I hoped. I now have a directory at the root level containing all my local web files.