[Cuis-dev] Cuis app for multi-user environment ??

Hilaire Fernandes hfern at free.fr
Sat May 17 14:09:01 PDT 2025


Hi,

I found the situation a bit difficult to set up a Cuis app for a 
multi-user environment.

The idea is to have the Cuis app installed as root in the host 
filesystem. The starter script of the cuis app, copies the image and 
other stuff on the user space, then the vm is started with this image.

All in all, I found myself in a lock-in lock-in situation.

In one hand  I use AppLauncher to launch the app once the command line 
options  to cuis image were handled. So path to user image, app 
resources are correct.

In the other hand, Cuis insists on logging early on file in its own 
startup process (in read only directory) and user change again in read 
only directory, before a -d option is executed (-d "DirectoryEntry 
setUserBaseDirectory: '$HOME/$USERDATA/Resources' asDirectoryEntry") to 
set the userBaseDirectory to the user space.

Main issue here, it seems DirectoryEntry userChangesDirectory did not 
get a chance to be changed to user space, so BOOM!

assureStartupStampLogged
     "If there is a startup stamp not yet actually logged to disk, do it 
now."
     "Note: This renames the existing user changes file, and creates a 
new one."
     | changesFile directory oldUserChanges |
     (SourceFiles notNil and: [(changesFile := SourceFiles at: 2) 
notNil]) ifTrue: [
         changesFile isReadOnly ifFalse: [
             changesFile setToEnd; newLine; newLine.
             changesFile nextChunkPut: StartupStamp; newLine.
             self forceChangesToDisk ]].
     (Preferences at: #autoNumberUserChanges) ifTrue: [
         oldUserChanges := DirectoryEntry userChangesDirectory // self 
userChangesFileName.
         oldUserChanges exists ifTrue: [
             directory := oldUserChanges parent.
             PreviousUserChangesName := directory nextNameFor: 
oldUserChanges nameWithoutExtension extension: 'changes'.
             oldUserChanges rename: PreviousUserChangesName ]].
*  DirectoryEntry userChangesDirectory *// self userChangesFileName 
appendStreamDo: [ :stream |
         stream newLine; newLine.
         stream nextChunkPut: StartupStamp; newLine.
         stream flush ].


-- 
http://mamot.fr/@drgeo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20250517/27bdaa2a/attachment.htm>


More information about the Cuis-dev mailing list