Summary
get-admin-credentials never returns when invoked on the stopped service, and it is the only way to clear the critical own-task raised at install. The task stays active, so package start refuses without --force — a fresh install cannot be started through the normal path.
Measured on a real box (StartOS 0.4.0.1, x86_64) against 34.0.3:0, and it reproduces on 34.0.3:1, so this is not caused by #134.
What was seen
start-cli package action run nextcloud get-admin-credentials <<< null
# no output; killed at 180 s, exit 124
adminPassword is present in store.json, and the handler reads only that, so the hang is not in the handler's data path.
package action get-input nextcloud set-config against the running service returns in well under a second, so the action plumbing in general is fine.
get-admin-credentials is this package's only allowedStatuses: 'only-stopped' action (startos/actions/getAdminCredentials.ts:14). Every other action is any or only-running.
Why it blocks the install
bootstrapNextcloud raises the task as critical (startos/init/bootstrapNextcloud.ts), and a critical task stops the service until it is resolved. A task with no when clause is only cleared by running the action — which is the thing that hangs. So the only exits are --force or editing state by hand.
Not diagnosed
I have not established whether the hang is in the handler, in the SDK's file-model path when no container is running, or in the OS's action-run path for a stopped service. The correlation with only-stopped is suggestive but it is a sample of one — the package has no other only-stopped action to compare against. Someone should determine that before picking a fix; a plausible first probe is a trivial only-stopped action that returns a constant and touches no file model.
Worth considering alongside
The current shape — seed a password at install, then a hidden one-shot action that consumes it (storeJson.merge(effects, { adminPassword: undefined }), getAdminCredentials.ts) — is the pattern the packaging guide's recipe-admin-credentials steers away from. The sanctioned shape is one setX action plus a setupOnInit watcher that raises the critical task while the field is unset and retracts once set. That would also remove the "runs exactly once, then fails Admin password not seeded forever" edge this action already has.
Summary
get-admin-credentialsnever returns when invoked on the stopped service, and it is the only way to clear thecriticalown-task raised at install. The task staysactive, sopackage startrefuses without--force— a fresh install cannot be started through the normal path.Measured on a real box (StartOS 0.4.0.1, x86_64) against
34.0.3:0, and it reproduces on34.0.3:1, so this is not caused by #134.What was seen
adminPasswordis present instore.json, and the handler reads only that, so the hang is not in the handler's data path.package action get-input nextcloud set-configagainst the running service returns in well under a second, so the action plumbing in general is fine.get-admin-credentialsis this package's onlyallowedStatuses: 'only-stopped'action (startos/actions/getAdminCredentials.ts:14). Every other action isanyoronly-running.Why it blocks the install
bootstrapNextcloudraises the task ascritical(startos/init/bootstrapNextcloud.ts), and acriticaltask stops the service until it is resolved. A task with nowhenclause is only cleared by running the action — which is the thing that hangs. So the only exits are--forceor editing state by hand.Not diagnosed
I have not established whether the hang is in the handler, in the SDK's file-model path when no container is running, or in the OS's action-run path for a stopped service. The correlation with
only-stoppedis suggestive but it is a sample of one — the package has no otheronly-stoppedaction to compare against. Someone should determine that before picking a fix; a plausible first probe is a trivialonly-stoppedaction that returns a constant and touches no file model.Worth considering alongside
The current shape — seed a password at install, then a hidden one-shot action that consumes it (
storeJson.merge(effects, { adminPassword: undefined }),getAdminCredentials.ts) — is the pattern the packaging guide'srecipe-admin-credentialssteers away from. The sanctioned shape is onesetXaction plus asetupOnInitwatcher that raises the critical task while the field is unset and retracts once set. That would also remove the "runs exactly once, then failsAdmin password not seededforever" edge this action already has.