No need to reinvent the wheel here. This functionality already exists in folder-add.tcl as referred to in this thread:
https://openacs.org/forums/message-view?message_id=467566I don't have my notes in front of me but I seem to recall that all I had to do was directly type in the URL of
http://mysite/myfilestorageinstance/folder-add and I was greeted with an input box in which to input the directory I wanted to import. I loaded almost 10 gigs in one whack. (The procedure does assume that the files to be imported are in a local filesystem on the server. However, if you
have enough time on your hands I would wager that something like sshfs would be acceptable if the files must be loaded remotely.)