I created a mount task and a share task. Both are triggered on log in of user. I had to use an inelegant 15 second delay in trigger for the share task to get the timing to work properly. I wonder if there's a better way to do that. AFAI can tell, there's no way to sequentially execute tasks, and because the tasks require different users, the regular action window won't work to sequentially execute.
Anyway, the set up works now, it could probably be improved if you have some ideas, but it wouldn't have been possible without your assistance!
set root=c:\data\rclone\scripts
set cur=%root%\rr\other\mount\
cd /d %root%
set RCLONE_CONFIG_PASS=fdsaasdf
set RCLONE_CONFIG=%root%\rclone.conf
set rcmd=%root%\rclone.exe
set logfile=%cur%\log.system.txt
set nslog=%cur%\ns.txt
set log=--log-file=%logfile% --log-level=INFO
set flags=--allow-other --vfs-cache-mode=writes --dir-cache-time=5m --user-agent="en07"
del %logfile%
del %nslog%
start %rcmd% mount wasabimediacrypt_user01: e: %flags% -vv
timeout /t 10
echo BEFORE NET SHARE>> %cur%\ns.txt
net share >> %cur%\ns.txt
echo RUNNING net share theshare=e: >> %cur%\ns.txt
net share theshare=e: >> %cur%\ns.txt
echo AFTER NET SHARE >> %cur%\ns.txt
net share >> %cur%\ns.txt
dir \\localhost\theshare >> %cur%\ns.txt
net share theshare=e: /grant:en07\user01,FULL /grant:en07\user01,FULL /grant:en07\block,read >> %cur%\ns.txt
net share theshare
Share name theshare
Path e:
Remark
Maximum users No limit
Users
Caching Manual caching of documents
Permission EN07\user01, FULL
EN07\block, READ
This doesn't work, because when I run the share task as system user after everything is loaded, and the rclone task is restarted, the share task works. However, when triggered on restart, using the actions screen to load the tasks sequentially, the share doesn't work (under SYSTEM user).
I've come to conclude that non-restart testing isn't conclusive.
net share theshare=e: /grant:en07\user01,FULL /grant:en07\user01,FULL /grant:en07\block,read /grant:Administrators,full >> %cur%\ns.txt
Share name theshare
Path e:
Remark
Maximum users No limit
Users
Caching Manual caching of documents
Permission EN07\user01, FULL
EN07\block, READ
BUILTIN\Administrators, FULL